Skip to content

Commit

Permalink
fix long property test values
Browse files Browse the repository at this point in the history
  • Loading branch information
jenschude committed Sep 15, 2023
1 parent 971fe66 commit 016cfe0
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,14 @@ class JavaBuilderTestRenderer constructor(override val vrapTypeProvider: VrapTyp
is ArrayType -> "Collections.singletonList(${propertyValue(name, type.items, r)})"
is BooleanType -> true
is IntegerType -> when (type.format) {
NumberFormat.LONG,
NumberFormat.INT64 -> "${r.nextInt(1, 10)}L"
else -> r.nextInt(1, 10)
}
is NumberType -> when (type.format) {
NumberFormat.DOUBLE -> r.nextDouble()
NumberFormat.FLOAT -> r.nextFloat()
NumberFormat.LONG,
NumberFormat.INT64 -> "${r.nextInt(1, 10)}L"
else -> r.nextInt(1, 10)
}
Expand Down

0 comments on commit 016cfe0

Please sign in to comment.