net.jqwik.testing.CheckReporting Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jqwik-testing Show documentation
Show all versions of jqwik-testing Show documentation
Jqwik Testing support module
The newest version!
package net.jqwik.testing;
import org.jspecify.annotations.*;
import org.mockito.*;
import net.jqwik.api.*;
import net.jqwik.api.lifecycle.*;
@NullMarked
public abstract class CheckReporting implements AroundPropertyHook {
Reporter reporter = Mockito.mock(Reporter.class);
@Override
public int aroundPropertyProximity() {
// Outside StatisticsHook
return -100;
}
@Override
public PropertyExecutionResult aroundProperty(PropertyLifecycleContext context, PropertyExecutor property) {
context.wrapReporter(ignore -> reporter);
PropertyExecutionResult result = property.execute();
check(reporter);
return result;
}
public abstract void check(Reporter mockReporter);
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy