Useful pytest Plugins
One of the main benefits of using pytest as the test runner for the Test Software is the large number of plugins that are available to extend the functionality of the test runner. The following plugins are commonly used by FixturFab when developing tests:
- pytest-html
- Generates a HTML report of the test results
- pytest-metadata
- Adds metadata to the test results
- Useful for adding information about the test environment
- pytest-order
- Allows for tests to be ordered
- Useful for tests that require a specific order
- pytest-print
- Prints the test results to the console
- Useful for debugging tests
- pytest-rerunfailures
- Reruns failed tests a specified number of times
- Great for tests that are flaky due to timing issues
- pytest-subtests
- Allows for subtests to be created within a test case
- Useful for tests that have multiple assertions
- Preferred alternative to using the
f3ts_assertfixture