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

Regex escape quote #2

Closed
wants to merge 1 commit into from
Closed

Regex escape quote #2

wants to merge 1 commit into from

Conversation

naholyr
Copy link
Contributor

@naholyr naholyr commented Mar 7, 2011

Escape unmatched single quotes in proposed regex.
Example: Given John's bag has color "blue"
will propose the properly escaped regex '/^John's bag has color "([^"]+)"$/'

Example: Given John's bag has color "blue"
will propose the properly escaped regex '/^John\'s bag has color "([^"]+)"$/'
@everzet
Copy link
Member

everzet commented Mar 19, 2011

merged in develop branch, thanks!

will be in next release!

@everzet everzet closed this Mar 19, 2011
wouterj pushed a commit to wouterj/Behat that referenced this pull request Jul 1, 2014
Define selenium2 capabilities as strings
pamil added a commit that referenced this pull request Jun 18, 2020
This PR was merged into the 3.8.x-dev branch.

Discussion
----------

I added "return 0" to fix this error message:

```
$ vendor/bin/behat --debug

behat version 3.7.0

--- configuration
    environment variable (BEHAT_PARAMS): none
    configuration file: /home/jawira/PhpstormProjects/xxxxxxxx/behat.yml

--- extensions
    extensions loaded: api_extension

PHP Fatal error:  Uncaught TypeError: Return value of "Behat\Testwork\Cli\DebugCommand::execute()" must be of the type int, NULL returned. in /home/jawira/PhpstormProjects/xxxxxxxx/vendor/symfony/console/Command/Command.php:258
Stack trace:
#0 /home/jawira/PhpstormProjects/xxxxxxxx/vendor/symfony/console/Application.php(912): Symfony\Component\Console\Command\Command->run()
#1 /home/jawira/PhpstormProjects/xxxxxxxx/vendor/symfony/console/Application.php(264): Symfony\Component\Console\Application->doRunCommand()
#2 /home/jawira/PhpstormProjects/xxxxxxxx/vendor/behat/behat/src/Behat/Testwork/Cli/Application.php(124): Symfony\Component\Console\Application->doRun()
#3 /home/jawira/PhpstormProjects/xxxxxxxx/vendor/symfony/console/Application.php(140): Behat\Testwork\Cli\Application->doRun()
#4 /home/jawira/PhpstormProjects/xxxxxxxx/vendor/behat/behat/bin/behat(34): Symfony\Component\Console\Application->run()
#5 {main}
  thrown in /home/jawira/PhpstormProjects/xxxxxxxx/vendor/symfony/console/Command/Command.php on line 258
```

Commits
-------

48a3636 Add "return 0" in DebugCommand.php
902b3c6 Add debug test
lorenzodalaqua referenced this pull request in lorenzodalaqua/Behat Jul 1, 2022
This is applicable to Scenarios which are a part of a Scenario Outline.
Each example in an outline would be appended an index to its name in the
output (ex: Chekote#1, Chekote#2, Chekote#3...), but in a behat --rerun, they are all
appended Chekote#1, which breaks IFT detection. Not having the Example number
is the way the script currently expects the output to be, so it was
removed.
lorenzodalaqua referenced this pull request in lorenzodalaqua/Behat Jul 1, 2022
This is applicable to Scenarios which are a part of a Scenario Outline.
Each example in an outline would be appended an index to its name in the
output (ex: Chekote#1, Chekote#2, Chekote#3...), but in a behat --rerun, they are all
appended Chekote#1, which breaks IFT detection. Not having the Example number
is the way the script currently expects the output to be, so it was
removed.
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