-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Refactor 'exampleRecord'-tests * Refactor 'DepreatedExampleRecord'-tests * Refactor 'exampleRecordWithArrayFields'-tests * Refactor 'exampleRecordWithBooleanFields'-tests * Refactor 'exampleRecordWithNumberFields'-tests * Refactor 'exampleRecordWithStringFields'-tests * Refactor 'exampleRecordWithIntegerFields'-tests * Refactor 'exampleEnum'-tests * Refactor 'deprecatedExampleEnum'-tests * Refactor 'exmapleRecordWithExampleEnumFields'-tests * Refactor 'exampleRecordWithExampleRecordFields'-tests * Refactor all model-tests to `TestSuite.java` * Refactor 'exampleRecordWithDefaultFields'-tests * Add Constructor & field assertion-methods * Refactor 'Record has fields'-tests * Refactor 'Record field'-tests * Refactor 'Class has Method'-tests * Refactor 'Record has/does not have Method'-tests
- Loading branch information
Showing
9 changed files
with
506 additions
and
698 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
package com.chrimle.example; | ||
|
||
import com.chrimle.example.utils.GeneratedEnumTestUtils; | ||
import com.chrimle.example.utils.GeneratedRecordTestUtils; | ||
|
||
public record TestSuite<DeprecatedExampleEnum extends Enum<DeprecatedExampleEnum>, ExampleEnum extends Enum<ExampleEnum>>( | ||
Class<DeprecatedExampleEnum> deprecatedExampleEnum, | ||
Class<?> deprecatedExampleRecord, | ||
Class<ExampleEnum> exampleEnum, | ||
Class<?> exampleRecord, | ||
Class<?> exampleRecordWithArrayFields, | ||
Class<?> exampleRecordWithBooleanFields, | ||
Class<?> exampleRecordWithDefaultFields, | ||
Class<?> exampleRecordWithExampleEnumFields, | ||
Class<?> exampleRecordWithExampleRecordFields, | ||
Class<?> exampleRecordWithIntegerFields, | ||
Class<?> exampleRecordWithNumberFields, | ||
Class<?> exampleRecordWithStringFields, | ||
boolean hasAdditionalModelTypeAnnotations, | ||
boolean hasAdditionalEnumTypeAnnotations, | ||
boolean useEnumCaseInsensitive, | ||
boolean serializableModel | ||
) { | ||
|
||
public void assertModels() { | ||
GeneratedEnumTestUtils.assertExampleEnum( | ||
exampleEnum, | ||
hasAdditionalEnumTypeAnnotations, | ||
useEnumCaseInsensitive | ||
); | ||
GeneratedEnumTestUtils.assertDeprecatedExampleEnum( | ||
deprecatedExampleEnum, | ||
hasAdditionalEnumTypeAnnotations, | ||
useEnumCaseInsensitive | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecord( | ||
exampleRecord, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertDeprecatedExampleRecord( | ||
deprecatedExampleRecord, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithBooleanFields( | ||
exampleRecordWithBooleanFields, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithExampleEnumFields( | ||
exampleRecordWithExampleEnumFields, | ||
exampleEnum, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithExampleRecordFields( | ||
exampleRecordWithExampleRecordFields, | ||
exampleRecord, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithIntegerFields( | ||
exampleRecordWithIntegerFields, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithNumberFields( | ||
exampleRecordWithNumberFields, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithStringFields( | ||
exampleRecordWithStringFields, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithArrayFields( | ||
exampleRecordWithArrayFields, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
GeneratedRecordTestUtils.assertExampleRecordWithDefaultFields( | ||
exampleRecordWithDefaultFields, | ||
hasAdditionalModelTypeAnnotations, | ||
serializableModel | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.