ffmpeg-6: fix COMPONENT_REVISION
[oi-userland.git] / components / python / pytest-black / patches / 01-test-no-checkdocs.patch
blob54c3896b65167e4ffac810db5990e2021643ddc0
1 https://github.com/shopkeep/pytest-black/issues/66
3 --- pytest-black-0.3.12/tests/test_black.py.orig
4 +++ pytest-black-0.3.12/tests/test_black.py
5 @@ -20,7 +20,7 @@
6 print('Hello, world')
7 """
9 - result = testdir.runpytest("--black")
10 + result = testdir.runpytest("--black", "-p", "no:cov", "-p", "no:mypy")
11 result.assert_outcomes(failed=1)
14 @@ -36,7 +36,7 @@
15 # replace trailing newline (stripped by testdir.makepyfile)
16 p = p.write(p.read() + "\n")
18 - result = testdir.runpytest("--black")
19 + result = testdir.runpytest("--black", "-p", "no:cov", "-p", "no:mypy")
20 result.assert_outcomes(passed=1)
23 @@ -54,17 +54,17 @@
24 p.write(contents)
26 # Test once to populate the cache
27 - result = testdir.runpytest("--black")
28 + result = testdir.runpytest("--black", "-p", "no:cov", "-p", "no:mypy")
29 result.assert_outcomes(passed=1)
31 # Run it again, it should be skipped
32 - result = testdir.runpytest("--black", "-rs")
33 + result = testdir.runpytest("--black", "-rs", "-p", "no:cov", "-p", "no:mypy")
34 result.assert_outcomes(skipped=1)
35 result.stdout.fnmatch_lines(["SKIP*previously passed black format checks"])
37 # Update the file and test again.
38 p.write(contents)
39 - result = testdir.runpytest("--black")
40 + result = testdir.runpytest("--black", "-p", "no:cov", "-p", "no:mypy")
41 result.assert_outcomes(passed=1)
44 @@ -92,7 +92,7 @@
45 # Rename pyproject.toml ¯\_(ツ)_/¯
46 testdir.run("mv", "test_exclude.pyproject.toml", "pyproject.toml")
48 - result = testdir.runpytest("--black")
49 + result = testdir.runpytest("--black", "-p", "no:checkdocs", "-p", "no:cov", "-p", "no:mypy")
50 result.assert_outcomes(skipped=1, passed=0)
53 @@ -129,7 +129,7 @@
54 # Rename pyproject.toml ¯\_(ツ)_/¯
55 testdir.run("mv", "test_exclude_folder.pyproject.toml", "pyproject.toml")
57 - result = testdir.runpytest("--black")
58 + result = testdir.runpytest("--black", "-p", "no:checkdocs", "-p", "no:cov", "-p", "no:mypy")
59 result.assert_outcomes(skipped=1, passed=0)
62 @@ -156,7 +156,7 @@
63 # Rename pyproject.toml ¯\_(ツ)_/¯
64 testdir.run("mv", "test_include.pyproject.toml", "pyproject.toml")
66 - result = testdir.runpytest("--black")
67 + result = testdir.runpytest("--black", "-p", "no:checkdocs", "-p", "no:cov", "-p", "no:mypy")
68 result.assert_outcomes(skipped=0, passed=1)
71 @@ -171,7 +171,7 @@
72 # replace trailing newline (stripped by testdir.makepyfile)
73 p = p.write(p.read() + "\n")
75 - result = testdir.runpytest("--black")
76 + result = testdir.runpytest("--black", "-p", "no:cov", "-p", "no:mypy")
77 result.assert_outcomes(passed=1)
79 out = "\n".join(result.stdout.lines)