Softwaretechnik-II/testing/AufgabeEmailMatcher/EmailMatcherFuzzTest.java

15 lines
465 B
Java
Raw Normal View History

2024-10-30 19:29:50 +01:00
import com.code_intelligence.jazzer.api.FuzzedDataProvider;
import com.code_intelligence.jazzer.junit.FuzzTest;
import java.security.InvalidParameterException;
public class EmailMatcherFuzzTest {
@FuzzTest
public static void fuzzerTestOneInput(FuzzedDataProvider data) {
String email = data.consumeString(100);
if(EmailMatcher.isValidEmail(email)) {
throw new InvalidParameterException("Valid email found!");
}
}
}