We currently have 9 examples we run after tests to check the code is working as expected. This code moves those examples into tests that can be run by pytest.
Added a new tests/integration directory
Placed tests that use subprocess.run to run the examples in this directory and marked them as integration tests
I prefixed set -e to ensure the test fails if any commands fail
I capture the stdout and print it to the terminal to mimic the previous behavior.
Updated pytest to skip integration tests unless requested with the --integration flag.
Updated ci.yml to run integration tests after unit tests, and appending the output to the coverage file.
We currently have 9 examples we run after tests to check the code is working as expected. This code moves those examples into tests that can be run by pytest.
tests/integration
directorysubprocess.run
to run the examples in this directory and marked them as integration testsset -e
to ensure the test fails if any commands fail--integration
flag.ci.yml
to run integration tests after unit tests, and appending the output to the coverage file.