fix printScenarioFail with multiple scenarios #3868

Merged
merged 1 commit into from Feb 13, 2017

Conversation

Projects
None yet
5 participants
@gimler
Contributor

gimler commented Dec 22, 2016

When you have run a feature file and mulitple scenarios fails.
Then in the exception message the step is always the last one.

I am not sure what conditionalFails means. See change.

@DavertMik

This comment has been minimized.

Show comment
Hide comment
@DavertMik

DavertMik Dec 22, 2016

Member

I'm not sure for the fix as it goes to Console which is the very general class and probably may cause side effects but I will try to reproduce the bug and fix it.

Member

DavertMik commented Dec 22, 2016

I'm not sure for the fix as it goes to Console which is the very general class and probably may cause side effects but I will try to reproduce the bug and fix it.

@gimler

This comment has been minimized.

Show comment
Hide comment
@gimler

gimler Dec 23, 2016

Contributor

I think i can provide a testcase for it

Contributor

gimler commented Dec 23, 2016

I think i can provide a testcase for it

@DavertMik

This comment has been minimized.

Show comment
Hide comment
@DavertMik

DavertMik Dec 26, 2016

Member

I think i can provide a testcase for it

Looking forward to see it. Thanks!

Member

DavertMik commented Dec 26, 2016

I think i can provide a testcase for it

Looking forward to see it. Thanks!

@Naktibalda

This comment has been minimized.

Show comment
Hide comment
@Naktibalda

Naktibalda Jan 14, 2017

Member

@gimler you promised to implement a test for your fix.
Hint: it should go to cli suite, please make something similar to https://github.com/Codeception/Codeception/blob/2.2/tests/cli/RunSkippedCept.php

Member

Naktibalda commented Jan 14, 2017

@gimler you promised to implement a test for your fix.
Hint: it should go to cli suite, please make something similar to https://github.com/Codeception/Codeception/blob/2.2/tests/cli/RunSkippedCept.php

@gimler gimler changed the title from fix printScenarioFail with multiple scenarios to [WIP] fix printScenarioFail with multiple scenarios Feb 1, 2017

src/Codeception/Scenario.php
+ {
+ return $this->metaStep;
+ }
+}

This comment has been minimized.

@Nitpick-CI

Nitpick-CI Feb 1, 2017

Expected 1 newline at end of file; 0 found

@Nitpick-CI

Nitpick-CI Feb 1, 2017

Expected 1 newline at end of file; 0 found

@gimler gimler changed the title from [WIP] fix printScenarioFail with multiple scenarios to fix printScenarioFail with multiple scenarios Feb 1, 2017

@gimler

This comment has been minimized.

Show comment
Hide comment
@gimler

gimler Feb 1, 2017

Contributor

@DavertMik @Naktibalda ready for review

Contributor

gimler commented Feb 1, 2017

@DavertMik @Naktibalda ready for review

@@ -354,6 +354,13 @@ public function runIncompleteGherkinTest(CliGuy $I)
$I->seeInShellOutput('Step definition for `I have only idea of what\'s going on here` not found in contexts');
}
+ public function runFailingGherkinTest(CliGuy $I)

This comment has been minimized.

@Naktibalda

Naktibalda Feb 7, 2017

Member

This test should be named reportsCorrectFailedStep to explain what it is testing.

@Naktibalda

Naktibalda Feb 7, 2017

Member

This test should be named reportsCorrectFailedStep to explain what it is testing.

This comment has been minimized.

@gimler

gimler Feb 8, 2017

Contributor

done

@gimler

gimler Feb 8, 2017

Contributor

done

@robsch

This comment has been minimized.

Show comment
Hide comment
@robsch

robsch Feb 8, 2017

Detected the same issue in another situation. I Hope the fix gets applied soon.

robsch commented Feb 8, 2017

Detected the same issue in another situation. I Hope the fix gets applied soon.

@Naktibalda Naktibalda merged commit 9696643 into Codeception:2.2 Feb 13, 2017

4 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
semaphoreci The build passed on Semaphore.
Details
wercker/build Wercker pipeline passed
Details
@Naktibalda

This comment has been minimized.

Show comment
Hide comment
@Naktibalda

Naktibalda Apr 16, 2017

Member

This change has broken the output of failed step: http://phptest.club/t/seeelement-wierd-fail-message/1470/3

Member

Naktibalda commented Apr 16, 2017

This change has broken the output of failed step: http://phptest.club/t/seeelement-wierd-fail-message/1470/3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment