net.jqwik.engine.providers.EnumArbitraryProvider Maven / Gradle / Ivy
package net.jqwik.engine.providers;
import java.util.*;
import net.jqwik.api.*;
import net.jqwik.api.providers.*;
public class EnumArbitraryProvider implements ArbitraryProvider {
@Override
public boolean canProvideFor(TypeUsage targetType) {
return targetType.isEnum();
}
@Override
public Set> provideFor(TypeUsage targetType, SubtypeProvider subtypeProvider) {
// noinspection unchecked
return Collections.singleton(Arbitraries.of((Class) targetType.getRawType()));
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy