Search in sources :

Example 1 with NoopAnnotator

use of org.jsonschema2pojo.NoopAnnotator in project jsonschema2pojo by joelittlejohn.

the class MinLengthMaxLengthRuleTest method setUp.

@Before
public void setUp() {
    MockitoAnnotations.initMocks(this);
    rule = new MinLengthMaxLengthRule(new RuleFactory(config, new NoopAnnotator(), new SchemaStore()));
    when(config.isUseJakartaValidation()).thenReturn(useJakartaValidation);
}
Also used : SchemaStore(org.jsonschema2pojo.SchemaStore) NoopAnnotator(org.jsonschema2pojo.NoopAnnotator) Before(org.junit.Before)

Example 2 with NoopAnnotator

use of org.jsonschema2pojo.NoopAnnotator in project jsonschema2pojo by joelittlejohn.

the class PatternRuleTest method setUp.

@Before
public void setUp() {
    MockitoAnnotations.initMocks(this);
    rule = new PatternRule(new RuleFactory(config, new NoopAnnotator(), new SchemaStore()));
    when(config.isUseJakartaValidation()).thenReturn(useJakartaValidation);
}
Also used : SchemaStore(org.jsonschema2pojo.SchemaStore) NoopAnnotator(org.jsonschema2pojo.NoopAnnotator) Before(org.junit.Before)

Example 3 with NoopAnnotator

use of org.jsonschema2pojo.NoopAnnotator in project jsonschema2pojo by joelittlejohn.

the class FormatRuleJodaTest method setupConfig.

@Before
public void setupConfig() {
    when(config.isUseJodaLocalTimes()).thenReturn(true);
    when(config.isUseJodaLocalDates()).thenReturn(true);
    when(config.isUseJodaDates()).thenReturn(true);
    rule = new FormatRule(new RuleFactory(config, new NoopAnnotator(), new SchemaStore()));
}
Also used : SchemaStore(org.jsonschema2pojo.SchemaStore) NoopAnnotator(org.jsonschema2pojo.NoopAnnotator) Before(org.junit.Before)

Example 4 with NoopAnnotator

use of org.jsonschema2pojo.NoopAnnotator in project jsonschema2pojo by joelittlejohn.

the class DigitsRuleTest method setUp.

@Before
public void setUp() {
    MockitoAnnotations.initMocks(this);
    rule = new DigitsRule(new RuleFactory(config, new NoopAnnotator(), new SchemaStore()));
    when(config.isUseJakartaValidation()).thenReturn(useJakartaValidation);
}
Also used : SchemaStore(org.jsonschema2pojo.SchemaStore) NoopAnnotator(org.jsonschema2pojo.NoopAnnotator) Before(org.junit.Before)

Example 5 with NoopAnnotator

use of org.jsonschema2pojo.NoopAnnotator in project jsonschema2pojo by joelittlejohn.

the class MinItemsMaxItemsRuleTest method setUp.

@Before
public void setUp() {
    MockitoAnnotations.initMocks(this);
    rule = new MinItemsMaxItemsRule(new RuleFactory(config, new NoopAnnotator(), new SchemaStore()));
    when(config.isUseJakartaValidation()).thenReturn(useJakartaValidation);
}
Also used : SchemaStore(org.jsonschema2pojo.SchemaStore) NoopAnnotator(org.jsonschema2pojo.NoopAnnotator) Before(org.junit.Before)

Aggregations

NoopAnnotator (org.jsonschema2pojo.NoopAnnotator)9 SchemaStore (org.jsonschema2pojo.SchemaStore)9 Before (org.junit.Before)6 DefaultGenerationConfig (org.jsonschema2pojo.DefaultGenerationConfig)3 Test (org.junit.Test)3 GenerationConfig (org.jsonschema2pojo.GenerationConfig)2 RuleLogger (org.jsonschema2pojo.RuleLogger)2