Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run behat fixture features against Cucumber parser #229

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ciaranmcnulty
Copy link
Contributor

To further document areas of difference with Cucumber, this uses the go binary releases to test that the AST produced by the real cucumber is the same as the AST behat produces

To further document areas of difference with Cucumber, this uses the go binary releases to test that the AST produced by the real cucumber is the same as the AST behat produces
@@ -118,7 +118,7 @@ private static function getBackground(array $json)
array_map(
static function ($child) {
return new BackgroundNode(
$child['background']['name'],
isset($child['background']['name']) ? $child['background']['name'] : null,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not using ??

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just forgot what versions we support

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, you used ?? in the same diff a few lines below 😄

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a good memory :)


if (isset($this->behatFeaturesCucumberCannotParseCorrectly[$ymlFile->getFilename()])){
$this->markTestIncomplete($this->behatFeaturesCucumberCannotParseCorrectly[$ymlFile->getFilename()]);
return;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this return is dead code as markTestIncomplete never returns but always throws

$newConfig = str_replace($oldTag, $newTag, $githubConfig);
file_put_contents($githubFile, $newConfig);

echo "Updated github build action:$newConfig\n";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you should put a \n before the new config, to be more readable (otherwise, the first line of the config is stuck with the message)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants