Correct --init & -dl command
For me, the instructions didn't work as-is.
Expected results:
Running bin/behat --init & bin/behat -dl would display the list of tests as the instructions say.
Actual results:
bin/behat -dl returned nothing.
How's this?
Behat is new to me, so I have only knowledge of what I encountered when I attempted to follow the installation instructions. Wasn't sure what to do about the file path in this text: "The features/FeatureContext.php file must be in the same directory as your behat.yml"
Maybe the underlying issue is that the instructions probably assume that behat would be run inside the directory with behat.yml. Is that the assumption?
If so, my changes probably aren't the best path to take -- would probably be better to add a step like
cd sites/default/behat-tests
Maybe the underlying issue is that the instructions probably assume that behat would be run inside the directory with behat.yml. Is that the assumption?
If so, my changes probably aren't the best path to take -- would probably be better to add a step like
cd sites/default/behat-tests
Yes that is the assumption, it would be a good idea to update the documentation with this suggestion.
It is not a good practice to put the tests inside the web root though, so maybe just use a generic example like:
$ cd /path/to/behat/tests
For most sites in Drupal 8, the webroot will be a subdirectory of the project root (eg, web or build/html, etc), and behat will be located in a sibling subdirectory (eg, test), so let's make that assumption for the docs fix. Also, the binary is now in vendor/bin/behat since we removed bin from our composer.json file.