public void scenarioNotAllowed(Scenario scenario, String s) { StepEventBus.getEventBus().testIgnored(); }
@Override public void scenarioNotAllowed(Scenario scenario, String s) { logger.debug("scenarioNotAllowed {}", scenario.getTitle()); StepEventBus.getEventBus().testIgnored(); }
public void suspendTest(TestResult result) { switch (result) { case PENDING: testPending(); break; case IGNORED: testIgnored(); break; case SKIPPED: testSkipped(); break; } }
@Override public void testIgnored(final Description description) throws Exception { if (testingThisTest(description)) { StepEventBus.getEventBus().testIgnored(); endTest(); } }
/** * Process any Thucydides annotations in the test class. * Ignored tests will just be skipped by JUnit - we need to ensure * that they are included in the Thucydides reports * If a test method is pending, all the steps should be skipped. */ private void processTestMethodAnnotationsFor(FrameworkMethod method) { if (isIgnored(method)) { stepListener.testStarted(Description.createTestDescription(method.getMethod().getDeclaringClass(), testName(method))); StepEventBus.getEventBus().testIgnored(); } }
public void assumptionViolated(String message) { testIgnored(); suspendTest(); stepDone(); getResultTally().logIgnoredTest(); for (StepListener stepListener : getAllListeners()) { stepListener.assumptionViolated(message); } assumptionViolated = true; assumptionViolatedMessage = message; }
public void assumptionViolated(String message) { testIgnored(); suspendTest(); stepDone(); getResultTally().logIgnoredTest(); for (StepListener stepListener : getAllListeners()) { stepListener.assumptionViolated(message); } assumptionViolated = true; assumptionViolatedMessage = message; }
public void assumptionViolated(String message) { testIgnored(); suspendTest(); stepDone(); getResultTally().logIgnoredTest(); for (StepListener stepListener : getAllListeners()) { stepListener.assumptionViolated(message); } assumptionViolated = true; assumptionViolatedMessage = message; }
public void beforeScenario(String scenarioTitle) { clearScenarioResult(); if (shouldRestartDriverBeforeEachScenario() && !shouldNestScenarios()) { WebdriverProxyFactory.resetDriver(ThucydidesWebDriverSupport.getDriver()); } if (shouldResetStepsBeforeEachScenario()) { ThucydidesStepFactory.resetContext(); } if(isCurrentScenario(scenarioTitle)) { //This is our scenario } else if (shouldNestScenarios()) { startNewStep(scenarioTitle); } else { startScenarioCalled(scenarioTitle); } if (pendingScenario()) { StepEventBus.getEventBus().testPending(); } else if (skippedScenario()) { StepEventBus.getEventBus().testIgnored(); } }
private void updateResultFromTags(List<Tag> scenarioTags) { if (isManual(scenarioTags)) { updateManualResultsFrom(scenarioTags); } else if (isPending(scenarioTags)) { getStepEventBus(currentFeaturePath()).testPending(); } else if (isSkippedOrWIP(scenarioTags)) { getStepEventBus(currentFeaturePath()).testSkipped(); getStepEventBus(currentFeaturePath()).getBaseStepListener().overrideResultTo(TestResult.SKIPPED); } else if (isIgnored(scenarioTags)) { getStepEventBus(currentFeaturePath()).testIgnored(); getStepEventBus(currentFeaturePath()).getBaseStepListener().overrideResultTo(TestResult.IGNORED); } }
private void updateResultFromTags(List<Tag> scenarioTags) { if (isManual(scenarioTags)) { updateManualResultsFrom(scenarioTags); } else if (isPending(scenarioTags)) { getStepEventBus(currentFeaturePath()).testPending(); } else if (isSkippedOrWIP(scenarioTags)) { getStepEventBus(currentFeaturePath()).testSkipped(); getStepEventBus(currentFeaturePath()).getBaseStepListener().overrideResultTo(TestResult.SKIPPED); } else if (isIgnored(scenarioTags)) { getStepEventBus(currentFeaturePath()).testIgnored(); getStepEventBus(currentFeaturePath()).getBaseStepListener().overrideResultTo(TestResult.IGNORED); } }
private void markAsSkippedOrPendingIfAnnotatedAsSuchIn(List<String> tags) { if (isManual(tags)) { StepEventBus.getEventBus().testIsManual(); } if (isSkipped(tags)) { StepEventBus.getEventBus().testSkipped(); StepEventBus.getEventBus().getBaseStepListener().overrideResultTo(TestResult.SKIPPED); } if (isPending(tags)) { StepEventBus.getEventBus().testPending(); StepEventBus.getEventBus().getBaseStepListener().overrideResultTo(TestResult.PENDING); } if (isIgnored(tags)) { StepEventBus.getEventBus().testIgnored(); StepEventBus.getEventBus().getBaseStepListener().overrideResultTo(TestResult.IGNORED); } }