summaryrefslogtreecommitdiff
path: root/src/main/java/au/id/zancanaro/javacheck/Generators.java
diff options
context:
space:
mode:
authorCarlo Zancanaro <carlo@zancanaro.id.au>2015-06-06 16:40:04 +1000
committerCarlo Zancanaro <carlo@zancanaro.id.au>2015-06-06 16:40:04 +1000
commit84f0f216b4643601e4b8760d190b087bbce98bd4 (patch)
tree5f9ea5c1087b5da6611c9a9c51ba076e55e4e9e3 /src/main/java/au/id/zancanaro/javacheck/Generators.java
parent05ec409ce96da92d430c4a8e58b08d46f42d667a (diff)
Lots of work on the stateful checking stuff: it's a fair bit nicer now
Diffstat (limited to 'src/main/java/au/id/zancanaro/javacheck/Generators.java')
-rw-r--r--src/main/java/au/id/zancanaro/javacheck/Generators.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/au/id/zancanaro/javacheck/Generators.java b/src/main/java/au/id/zancanaro/javacheck/Generators.java
index 619fe2d..f4ac025 100644
--- a/src/main/java/au/id/zancanaro/javacheck/Generators.java
+++ b/src/main/java/au/id/zancanaro/javacheck/Generators.java
@@ -40,7 +40,8 @@ public final class Generators {
return integer(0, gens.length).flatMap(index -> gens[index].map(x -> (T) x));
}
- public static <T> Generator<T> elements(T[] elements) {
+ @SafeVarargs
+ public static <T> Generator<T> elements(T... elements) {
return elements(Arrays.asList(elements));
}