numbered list
This commit is contained in:
10
README.md
10
README.md
@@ -52,10 +52,10 @@ Usage
|
|||||||
|
|
||||||
After installing extension, there would be 5 usage options available for you:
|
After installing extension, there would be 5 usage options available for you:
|
||||||
|
|
||||||
* Writing features with bundled steps only. In this case, you don't need to create
|
1. Writing features with bundled steps only. In this case, you don't need to create
|
||||||
`boostrap/` folder or custom `FeatureContext` class - Behat will use default
|
`boostrap/` folder or custom `FeatureContext` class - Behat will use default
|
||||||
`MinkContext` by default.
|
`MinkContext` by default.
|
||||||
* Subcontexting/extending `Behat\MinkExtension\Context\RawMinkContext` in your feature suite.
|
2. Subcontexting/extending `Behat\MinkExtension\Context\RawMinkContext` in your feature suite.
|
||||||
This will give you ability to use preconfigured `Mink` instance altogether with some
|
This will give you ability to use preconfigured `Mink` instance altogether with some
|
||||||
convenience methods:
|
convenience methods:
|
||||||
|
|
||||||
@@ -64,15 +64,15 @@ After installing extension, there would be 5 usage options available for you:
|
|||||||
|
|
||||||
`RawMinkContext` doesn't provide any hooks or definitions, so you can inherit from it
|
`RawMinkContext` doesn't provide any hooks or definitions, so you can inherit from it
|
||||||
in as many subcontexts as you want - you'll never get `RedundantStepException`.
|
in as many subcontexts as you want - you'll never get `RedundantStepException`.
|
||||||
* Subcontexting/extending `Behat\MinkExtension\Context\MinkContext` in your feature suite.
|
3. Subcontexting/extending `Behat\MinkExtension\Context\MinkContext` in your feature suite.
|
||||||
Exactly like previous option, but also provides lot of predefined step definitions out
|
Exactly like previous option, but also provides lot of predefined step definitions out
|
||||||
of the box. As this context provides step definitions and hooks, you can use it **only once**
|
of the box. As this context provides step definitions and hooks, you can use it **only once**
|
||||||
inside your feature context tree.
|
inside your feature context tree.
|
||||||
* If you're on the php 5.4+, you can simply use `Behat\MinkExtension\Context\MinkDictionary`
|
4. If you're on the php 5.4+, you can simply use `Behat\MinkExtension\Context\MinkDictionary`
|
||||||
trait inside your `FeatureContext` or any of its subcontexts. This trait will provide
|
trait inside your `FeatureContext` or any of its subcontexts. This trait will provide
|
||||||
all the needed methods, hooks and definitions for you to start. You can use this trait **only
|
all the needed methods, hooks and definitions for you to start. You can use this trait **only
|
||||||
once** inside your feature context tree.
|
once** inside your feature context tree.
|
||||||
* Implementing `Behat\MinkExtension\Context\MinkAwareContextInterface` with your context or its
|
5. Implementing `Behat\MinkExtension\Context\MinkAwareContextInterface` with your context or its
|
||||||
subcontexts.
|
subcontexts.
|
||||||
This will give you more customization options. Also, you can use this mechanism on multiple
|
This will give you more customization options. Also, you can use this mechanism on multiple
|
||||||
contexts avoiding the need to call parent contexts from subcontexts when only thing you need
|
contexts avoiding the need to call parent contexts from subcontexts when only thing you need
|
||||||
|
|||||||
Reference in New Issue
Block a user