Skip to content

Commit afe8c75

Browse files
committed
Improve metadata
1 parent 4857c84 commit afe8c75

File tree

3 files changed

+24
-6
lines changed

3 files changed

+24
-6
lines changed

README.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,15 @@ def test_that_modifies_env() -> None:
1515
os.environ['CUSTOM_ENV'] = '1'
1616
```
1717

18-
With `pytest-modified-env` plugin installed, this test will fail.
19-
Because it adds `CUSTOM_ENV` inside a test and does not clean it up.
18+
With `pytest-modified-env` plugin installed, this test will fail:
2019

20+
```
21+
___________________________ test_that_modifies_env ____________________________
22+
test_that_modifies_env:4: in pytest_runtest_call
23+
E RuntimeError: os.environ was changed
24+
```
25+
26+
Because it adds `CUSTOM_ENV` inside a test and does not clean it up.
2127
In theory it can affect other tests and tests should be isolated!
2228

2329

pyproject.toml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,28 @@ description = "Pytest plugin to fail a test if it leaves modified `os.environ` a
1313
version = "0.1.0"
1414
license = "MIT"
1515

16-
authors = []
16+
authors = [
17+
"Nikita Sobolev <[email protected]>"
18+
]
1719

1820
readme = "README.md"
1921

2022
repository = "https://github.com/wemake-services/pytest-modified-env"
2123

22-
keywords = []
24+
keywords = [
25+
"pytest",
26+
"pytest-plugin",
27+
"os.environ",
28+
"testing",
29+
"unittest",
30+
"tests",
31+
"test",
32+
"unit tests",
33+
"code quality",
34+
]
2335

2436
classifiers = [
25-
"Development Status :: 3 - Alpha",
37+
"Development Status :: 4 - Beta",
2638
"Intended Audience :: Developers",
2739
"Operating System :: OS Independent",
2840
"Topic :: Software Development :: Libraries :: Python Modules",

tests/test_env_modifications.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def test_allowed() -> None:
2323
os.environ['MARKER_ENV'] = '1'
2424

2525

26-
@pytest.mark.xfail(reason='Env is modified')
26+
2727
def test_expected_to_fail() -> None:
2828
"""
2929
This test modifies the env.

0 commit comments

Comments
 (0)