@ -98,11 +96,11 @@ public class RandomValuePropertySource extends PropertySource<Random> {
@@ -98,11 +96,11 @@ public class RandomValuePropertySource extends PropertySource<Random> {
@ -120,24 +118,22 @@ public class RandomValuePropertySource extends PropertySource<Random> {
@@ -120,24 +118,22 @@ public class RandomValuePropertySource extends PropertySource<Random> {
Assert.state(present,()->"Could not get random number for range '"+range+"'");
}
privateObjectgetRandomBytes(){
byte[]bytes=newbyte[32];
getSource().nextBytes(bytes);
@ -167,27 +163,16 @@ public class RandomValuePropertySource extends PropertySource<Random> {
@@ -167,27 +163,16 @@ public class RandomValuePropertySource extends PropertySource<Random> {
Assert.isTrue(boundValidator.test(token1),"Bound must be positive.");
returnnewRange<>(defaultMin,token1);
}
Ttoken2=parse.apply(tokens[1]);
Assert.isTrue(rangeValidator.test(token1,token2),"Lower bound must be less than upper bound.");
returnnewRange<>(token1,token2);
}
TgetMin(){
@ -198,6 +183,24 @@ public class RandomValuePropertySource extends PropertySource<Random> {
@@ -198,6 +183,24 @@ public class RandomValuePropertySource extends PropertySource<Random> {