pytest-bdd
pytest-bdd copied to clipboard
Add support for worlds
Cucumber runs scenarios in a world, and different worlds can be created that execute the steps differently, depending on the world. For example, a Web UI world could execute a step by interacting with a web page in a browser (i.e. navigating, entering input, clicking buttons/links, etc); an iOS or Android world could execute the same steps in a native iOS or Android app; an API world could execute the exact same steps simply by calling API endpoints with no interaction with a UI at all; etc. This feature is incredibly useful from a maintenance perspective, since it allows you to have a single place to define all of your step definitions using a ubiquitous language, while at the same time being able to define the actual execution of each step in a separate world file/object.
See the Cucumber wiki for more information on this feature.