Test that cmd.run passes extra environment variables.
(self)
| 65 | assert "hello" in c.out |
| 66 | |
| 67 | def test_with_env(self): |
| 68 | """Test that cmd.run passes extra environment variables.""" |
| 69 | c = cmd.run( |
| 70 | ["python", "-c", "import os; print(os.environ['CZ_TEST_VAR'])"], |
| 71 | env={"CZ_TEST_VAR": "test_value"}, |
| 72 | ) |
| 73 | assert c.return_code == 0 |
| 74 | assert "test_value" in c.out |
| 75 | |
| 76 | def test_with_string_emits_deprecation_warning(self): |
| 77 | """Test that passing a string to cmd.run() emits a DeprecationWarning.""" |
nothing calls this directly
no outgoing calls
no test coverage detected