Package net.thucydides.core.model

Examples of net.thucydides.core.model.TestOutcome


        StepEventBus.getEventBus().testFinished(testOutcome);

        StepEventBus.getEventBus().testStarted("app should still work", MyStory.class);
        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome outcome = stepListener.getTestOutcomes().get(0);
        assertThat(outcome.getUserStory().getName(), is("My story"));

        TestOutcome outcome2 = stepListener.getTestOutcomes().get(1);
        assertThat(outcome2.getUserStory().getName(), is("My story"));

    }
View Full Code Here


        StepEventBus.getEventBus().testSuiteFinished();
        StepEventBus.getEventBus().testSuiteStarted(MyOtherStory.class);
        StepEventBus.getEventBus().testStarted("the app should work", MyOtherStory.class);
        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome outcome1 = stepListener.getTestOutcomes().get(0);
        assertThat(outcome1.getUserStory().getName(), is("My story"));

        TestOutcome outcome2 = stepListener.getTestOutcomes().get(1);
        assertThat(outcome2.getUserStory().getName(), is("My story"));

        TestOutcome outcome3 = stepListener.getTestOutcomes().get(2);
        assertThat(outcome3.getUserStory().getName(), is("My other story"));


    }
View Full Code Here

        steps.step_one();
        steps.step_two();

        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome outcome = stepListener.getTestOutcomes().get(0);
        assertThat(outcome.getUserStory().getName(), is("My test case without a story"));
    }
View Full Code Here

        steps.step_one();
        steps.step_two();

        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome outcome = stepListener.getTestOutcomes().get(0);
        net.thucydides.core.model.Story story = outcome.getUserStory();
        assertThat(story.getStoryClassName(), is(MyStory.class.getName()));
    }
View Full Code Here

        FlatScenarioSteps steps = stepFactory.getStepLibraryFor(FlatScenarioSteps.class);
        steps.step_one();
        steps.step_two();
        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome outcome = stepListener.getTestOutcomes().get(0);
        ApplicationFeature feature = outcome.getFeature();
        assertThat(feature.getId(), is(MyFeature.class.getCanonicalName()));
    }
View Full Code Here

        FlatScenarioSteps steps = stepFactory.getStepLibraryFor(FlatScenarioSteps.class);
        steps.step_one();
        steps.step_two();
        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome outcome = stepListener.getTestOutcomes().get(0);
        ApplicationFeature feature = outcome.getFeature();
        assertThat(feature.getName(), is("My feature"));
    }
View Full Code Here

        steps.step_one();
        steps.step_two();
        StepEventBus.getEventBus().testFinished(testOutcome);

        List<TestOutcome> results = stepListener.getTestOutcomes();
        TestOutcome testOutcome = results.get(0);
        assertThat(testOutcome.getTitle(), is("App should work"));
    }
View Full Code Here

        steps.step_one();
        steps.step_two();
        StepEventBus.getEventBus().testFinished(testOutcome);

        List<TestOutcome> results = stepListener.getTestOutcomes();
        TestOutcome testOutcome = results.get(0);
        assertThat(testOutcome.getTitle(), is("App should work"));
    }
View Full Code Here

        StepEventBus.getEventBus().testStarted("app_should_work");

        List<TestOutcome> results = stepListener.getTestOutcomes();
        StepEventBus.getEventBus().testFinished(testOutcome);

        TestOutcome testOutcome = results.get(0);
        assertThat(testOutcome.getMethodName(), is("app_should_work"));
    }
View Full Code Here

        steps.step_one();
        steps.step_two();
        StepEventBus.getEventBus().testFinished(testOutcome);

        List<TestOutcome> results = stepListener.getTestOutcomes();
        TestOutcome testOutcome = results.get(0);

        assertThat(testOutcome.getResult(), is(TestResult.SUCCESS));
    }
View Full Code Here

TOP

Related Classes of net.thucydides.core.model.TestOutcome

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.