-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Maintenance: remove package handling for model examples, add test cases
- Loading branch information
Showing
37 changed files
with
60 additions
and
103 deletions.
There are no files selected for viewing
13 changes: 13 additions & 0 deletions
13
gen/test/java/testapi/packages/model/MultipartTestExample.java
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,13 @@ | ||
package testapi.packages.model; | ||
|
||
public class MultipartTestExample { | ||
|
||
public static Multipart build() { | ||
Multipart exampleInstance = new Multipart(); | ||
exampleInstance.setOrderId(12); | ||
exampleInstance.setUserId(12); | ||
exampleInstance.setFileName("string"); | ||
exampleInstance.setFile("byteArray".getBytes()); | ||
return exampleInstance; | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
gen/test/java/testapi/packages/model/NumberModelTestExample.java
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,10 @@ | ||
package testapi.packages.model; | ||
|
||
public class NumberModelTestExample { | ||
|
||
public static NumberModel build() { | ||
NumberModel exampleInstance = new NumberModel(); | ||
exampleInstance.setBar(12.34); | ||
return exampleInstance; | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
gen/test/java/testapi/packages/model/ParameterModelTestExample.java
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,19 @@ | ||
package testapi.packages.model; | ||
|
||
public class ParameterModelTestExample { | ||
|
||
public static ParameterModel build() { | ||
ParameterModel exampleInstance = new ParameterModel(); | ||
exampleInstance.setBool("string"); | ||
exampleInstance.setString("string"); | ||
exampleInstance.setNumber(12.34); | ||
exampleInstance.setInteger(12); | ||
exampleInstance.setUuid(java.util.UUID.randomUUID()); | ||
exampleInstance.setDate(null); | ||
exampleInstance.setDateTime(null); | ||
exampleInstance.setA(java.util.List.of()); | ||
exampleInstance.setB(java.util.List.of()); | ||
exampleInstance.setC(java.util.List.of()); | ||
return exampleInstance; | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
gen/test/java/testapi/packages/model/StringModelTestExample.java
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,10 @@ | ||
package testapi.packages.model; | ||
|
||
public class StringModelTestExample { | ||
|
||
public static StringModel build() { | ||
StringModel exampleInstance = new StringModel(); | ||
exampleInstance.setFoo("string"); | ||
return exampleInstance; | ||
} | ||
} |
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/AdditionalPropertiesModelTestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/AdditionalPropertiesModelValueTestExample.java
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 |
---|---|---|
@@ -1,11 +1,8 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.AdditionalPropertiesModelValue.*; | ||
|
||
public class AdditionalPropertiesModelValueTestExample { | ||
|
||
public static AdditionalPropertiesModelValue build() { | ||
// use the first found implementation as example | ||
return PropertyTypeOneTestExample.build(); | ||
} | ||
} |
2 changes: 0 additions & 2 deletions
2
gen/test/java/testmodel/nomicronaut/EnumerationIntegerTestExample.java
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
7 changes: 2 additions & 5 deletions
7
gen/test/java/testmodel/nomicronaut/EnumerationModelTestExample.java
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 |
---|---|---|
@@ -1,16 +1,13 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.EnumerationModel.*; | ||
|
||
public class EnumerationModelTestExample { | ||
|
||
public static EnumerationModel build() { | ||
EnumerationModel exampleInstance = new EnumerationModel(); | ||
//initialize fields | ||
exampleInstance.setString(null); | ||
exampleInstance.setStringDefault(null); | ||
exampleInstance.setEmbedded(Embedded.toEnum("first")); | ||
exampleInstance.setEmbeddedDefault(EmbeddedDefault.toEnum("four")); | ||
exampleInstance.setEmbedded(EnumerationModel.Embedded.toEnum("first")); | ||
exampleInstance.setEmbeddedDefault(EnumerationModel.EmbeddedDefault.toEnum("four")); | ||
return exampleInstance; | ||
} | ||
} |
2 changes: 0 additions & 2 deletions
2
gen/test/java/testmodel/nomicronaut/EnumerationNumberTestExample.java
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
2 changes: 0 additions & 2 deletions
2
gen/test/java/testmodel/nomicronaut/EnumerationStringDefaultTestExample.java
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
2 changes: 0 additions & 2 deletions
2
gen/test/java/testmodel/nomicronaut/EnumerationStringTestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/FirstModelTestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceExtendedTestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceSimpleTestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithEnumType1TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithEnumType2TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithEnumType3TestExample.java
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 |
---|---|---|
@@ -1,12 +1,9 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.InheritanceWithEnumType3.*; | ||
|
||
public class InheritanceWithEnumType3TestExample { | ||
|
||
public static InheritanceWithEnumType3 build() { | ||
InheritanceWithEnumType3 exampleInstance = new InheritanceWithEnumType3(); | ||
//initialize fields | ||
return exampleInstance; | ||
} | ||
} |
2 changes: 0 additions & 2 deletions
2
gen/test/java/testmodel/nomicronaut/InheritanceWithEnumTypeEnumTestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithEnumTypeTestExample.java
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 |
---|---|---|
@@ -1,11 +1,8 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.InheritanceWithEnumType.*; | ||
|
||
public class InheritanceWithEnumTypeTestExample { | ||
|
||
public static InheritanceWithEnumType build() { | ||
// use the first found implementation as example | ||
return InheritanceWithEnumType1TestExample.build(); | ||
} | ||
} |
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithStringType1TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithStringType2TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithStringTypeTestExample.java
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 |
---|---|---|
@@ -1,11 +1,8 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.InheritanceWithStringType.*; | ||
|
||
public class InheritanceWithStringTypeTestExample { | ||
|
||
public static InheritanceWithStringType build() { | ||
// use the first found implementation as example | ||
return InheritanceWithStringType1TestExample.build(); | ||
} | ||
} |
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithoutType1TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithoutType2TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/InheritanceWithoutTypeTestExample.java
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 |
---|---|---|
@@ -1,11 +1,8 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.InheritanceWithoutType.*; | ||
|
||
public class InheritanceWithoutTypeTestExample { | ||
|
||
public static InheritanceWithoutType build() { | ||
// use the first found implementation as example | ||
return InheritanceWithoutType1TestExample.build(); | ||
} | ||
} |
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/OneOfImplementor1TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/OneOfImplementor2TestExample.java
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
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/OneOfInterfaceTestExample.java
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 |
---|---|---|
@@ -1,11 +1,8 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.OneOfInterface.*; | ||
|
||
public class OneOfInterfaceTestExample { | ||
|
||
public static OneOfInterface build() { | ||
// use the first found implementation as example | ||
return OneOfImplementor1TestExample.build(); | ||
} | ||
} |
3 changes: 0 additions & 3 deletions
3
gen/test/java/testmodel/nomicronaut/OneOfModelTestExample.java
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 |
---|---|---|
@@ -1,11 +1,8 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.OneOfModel.*; | ||
|
||
public class OneOfModelTestExample { | ||
|
||
public static OneOfModel build() { | ||
// use the first found implementation as example | ||
return FirstModelTestExample.build(); | ||
} | ||
} |
5 changes: 1 addition & 4 deletions
5
gen/test/java/testmodel/nomicronaut/PropertyTypeOneTestExample.java
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 |
---|---|---|
@@ -1,13 +1,10 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.PropertyTypeOne.*; | ||
|
||
public class PropertyTypeOneTestExample { | ||
|
||
public static PropertyTypeOne build() { | ||
PropertyTypeOne exampleInstance = new PropertyTypeOne(); | ||
//initialize fields | ||
exampleInstance.setType(Type.toEnum("one")); | ||
exampleInstance.setType(PropertyTypeOne.Type.toEnum("one")); | ||
return exampleInstance; | ||
} | ||
} |
5 changes: 1 addition & 4 deletions
5
gen/test/java/testmodel/nomicronaut/PropertyTypeTwoTestExample.java
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 |
---|---|---|
@@ -1,13 +1,10 @@ | ||
package testmodel.nomicronaut; | ||
|
||
import testmodel.nomicronaut.PropertyTypeTwo.*; | ||
|
||
public class PropertyTypeTwoTestExample { | ||
|
||
public static PropertyTypeTwo build() { | ||
PropertyTypeTwo exampleInstance = new PropertyTypeTwo(); | ||
//initialize fields | ||
exampleInstance.setType(Type.toEnum("two")); | ||
exampleInstance.setType(PropertyTypeTwo.Type.toEnum("two")); | ||
return exampleInstance; | ||
} | ||
} |
Oops, something went wrong.