Java 类org.junit.platform.engine.reporting.ReportEntry 实例源码

项目:jqwik    文件:CheckedProperty.java   
public PropertyCheckResult check(Consumer<ReportEntry> publisher) {
    long effectiveSeed = configuration.getSeed() == Property.SEED_NOT_SET ? RNG.get().nextLong() : configuration.getSeed();
    PropertyConfiguration effectiveConfiguration = configuration.withSeed(effectiveSeed);
    try {
        return createGenericProperty().check(effectiveConfiguration, publisher);
    } catch (CannotFindArbitraryException cannotFindArbitraryException) {
        return PropertyCheckResult.erroneous(effectiveConfiguration.getStereotype(), propertyName, 0, 0, effectiveConfiguration.getSeed(), Collections.emptyList(), cannotFindArbitraryException);
    }
}
项目:jqwik    文件:PropertyMethodExecutor.java   
private TestExecutionResult executeMethod(Object testInstance, EngineExecutionListener listener) {
    try {
        Consumer<ReportEntry> reporter = (ReportEntry entry) -> listener.reportingEntryPublished(methodDescriptor, entry);
        PropertyCheckResult propertyExecutionResult = executeProperty(testInstance, reporter);
        TestExecutionResult testExecutionResult = createTestExecutionResult(propertyExecutionResult);
        return testExecutionResult;
    } catch (TestAbortedException e) {
        return aborted(e);
    } catch (Throwable t) {
        rethrowIfBlacklisted(t);
        return failed(t);
    }
}
项目:jqwik    文件:CheckResultReportEntry.java   
public static ReportEntry from(PropertyCheckResult checkResult) {
    Map<String, String> entries = new HashMap<>();
    entries.put(SEED_REPORT_KEY, Long.toString(checkResult.randomSeed()));
    entries.put(TRIES_REPORT_KEY, Integer.toString(checkResult.countTries()));
    entries.put(CHECKS_REPORT_KEY, Integer.toString(checkResult.countChecks()));
    checkResult.sample().ifPresent(sample -> {
        if (!sample.isEmpty())
            entries.put(SAMPLE_REPORT_KEY, JqwikStringSupport.displayString(sample));
    });
    checkResult.originalSample().ifPresent(sample -> {
        if (!sample.isEmpty())
            entries.put(ORIGINAL_SAMPLE_REPORT_KEY, JqwikStringSupport.displayString(sample));
    });
    return ReportEntry.from(entries);
}
项目:junit-extensions    文件:RecordingExecutionListener.java   
@Override
public void reportingEntryPublished(TestDescriptor testDescriptor, ReportEntry entry) {
  addEvent(ExecutionEvent.reportingEntryPublished(testDescriptor, entry));
}
项目:junit-extensions    文件:ExecutionEvent.java   
public static ExecutionEvent reportingEntryPublished(
    TestDescriptor testDescriptor, ReportEntry entry) {
  return new ExecutionEvent(REPORTING_ENTRY_PUBLISHED, testDescriptor, entry);
}
项目:jqwik    文件:PropertyMethodExecutor.java   
private PropertyCheckResult executeProperty(Object testInstance, Consumer<ReportEntry> publisher) {
    CheckedProperty property = checkedPropertyFactory.fromDescriptor(methodDescriptor, testInstance);
    return property.check(publisher);
}
项目:junit-pioneer    文件:ExecutionEvent.java   
public static ExecutionEvent reportingEntryPublished(TestDescriptor testDescriptor, ReportEntry entry) {
    return new ExecutionEvent(REPORTING_ENTRY_PUBLISHED, testDescriptor, entry);
}
项目:junit-pioneer    文件:ExecutionEventRecorder.java   
@Override
public void reportingEntryPublished(TestDescriptor testDescriptor, ReportEntry entry) {
    addEvent(ExecutionEvent.reportingEntryPublished(testDescriptor, entry));
}
项目:junit5-docker    文件:JupiterExecutionListener.java   
@Override
public void reportingEntryPublished(TestDescriptor testDescriptor, ReportEntry reportEntry) {

}
项目:webtester2-core    文件:TestClassExecutor.java   
@Override
public void reportingEntryPublished(TestDescriptor testDescriptor, ReportEntry entry) {

}