net.corda.contracts.testing

## Class ContractStateGenerator

- net.corda.contracts.testing.ContractStateGenerator

-     public class ContractStateGenerator

  This file contains generators for quickcheck style testing. The idea is that we can write random instance generators for each type we have in the code and test against those instead of predefined mock data. This style of testing can catch corner case bugs and test algebraic properties of the code, for example deserialize(serialize(generatedThing)) == generatedThing

  TODO add combinators for easier Generator writing

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ContractStateGenerator()` This file contains generators for quickcheck style testing. The idea is that we can write random instance generators for each type we have in the code and test against those instead of predefined mock data. This style of testing can catch corner case bugs and test algebraic properties of the code, for example deserialize(serialize(generatedThing)) == generatedThing

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `ContractState` | `generate(com.pholser.junit.quickcheck.random.SourceOfRandomness random, com.pholser.junit.quickcheck.generator.GenerationStatus status)`

- - ### Constructor Detail

    - #### ContractStateGenerator

          public ContractStateGenerator()

      This file contains generators for quickcheck style testing. The idea is that we can write random instance generators for each type we have in the code and test against those instead of predefined mock data. This style of testing can catch corner case bugs and test algebraic properties of the code, for example deserialize(serialize(generatedThing)) == generatedThing

      TODO add combinators for easier Generator writing

  - ### Method Detail

    - #### generate

          public ContractState generate(com.pholser.junit.quickcheck.random.SourceOfRandomness random,
                                        com.pholser.junit.quickcheck.generator.GenerationStatus status)