pytest-pyspec 0.5.3__py3-none-any.whl → 1.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pytest-pyspec might be problematic. Click here for more details.
- pytest_pyspec/plugin.py +138 -30
- pytest_pyspec/tree.py +386 -0
- pytest_pyspec-1.0.0.dist-info/METADATA +202 -0
- pytest_pyspec-1.0.0.dist-info/RECORD +8 -0
- {pytest_pyspec-0.5.3.dist-info → pytest_pyspec-1.0.0.dist-info}/WHEEL +1 -1
- pytest_pyspec-1.0.0.dist-info/entry_points.txt +2 -0
- pytest_pyspec-1.0.0.dist-info/licenses/LICENSE +9 -0
- pytest_pyspec/item.py +0 -141
- pytest_pyspec/output.py +0 -30
- pytest_pyspec-0.5.3.dist-info/LICENSE +0 -674
- pytest_pyspec-0.5.3.dist-info/METADATA +0 -80
- pytest_pyspec-0.5.3.dist-info/RECORD +0 -9
- pytest_pyspec-0.5.3.dist-info/entry_points.txt +0 -3
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.1
|
|
2
|
-
Name: pytest-pyspec
|
|
3
|
-
Version: 0.5.3
|
|
4
|
-
Summary: A plugin that transforms the pytest output into a result similar to the RSpec. It enables the use of docstrings to display results and also enables the use of the prefixes "describe", "with" and "it".
|
|
5
|
-
Home-page: https://github.com/felipecrp/pytest-pyspec
|
|
6
|
-
License: GPL-3.0-only
|
|
7
|
-
Author: Felipe Curty
|
|
8
|
-
Author-email: felipecrp@gmail.com
|
|
9
|
-
Requires-Python: >=3.8,<4.0
|
|
10
|
-
Classifier: Development Status :: 5 - Production/Stable
|
|
11
|
-
Classifier: Framework :: Pytest
|
|
12
|
-
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
|
|
13
|
-
Classifier: Programming Language :: Python :: 3
|
|
14
|
-
Classifier: Programming Language :: Python :: 3.8
|
|
15
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
16
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
17
|
-
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
-
Classifier: Topic :: Software Development :: Testing
|
|
19
|
-
Requires-Dist: pytest (>=7.2.1,<8.0.0)
|
|
20
|
-
Project-URL: Repository, https://github.com/felipecrp/pytest-pyspec
|
|
21
|
-
Description-Content-Type: text/markdown
|
|
22
|
-
|
|
23
|
-
[](https://github.com/felipecrp/pytest-pyspec/actions/workflows/pytest.yml)
|
|
24
|
-
|
|
25
|
-
The **pytest-pyspec** plugin transforms the pytest output into a result similar to the RSpec.
|
|
26
|
-
|
|
27
|
-
Just nest your tests using classes and include _docstring_ for each class and test. You can create any nested levels.
|
|
28
|
-
|
|
29
|
-
The following test sample:
|
|
30
|
-
|
|
31
|
-
```python
|
|
32
|
-
import pytest
|
|
33
|
-
|
|
34
|
-
class TestHouse:
|
|
35
|
-
"a House"
|
|
36
|
-
|
|
37
|
-
def test_door(self):
|
|
38
|
-
"has door"
|
|
39
|
-
assert 1 == 1
|
|
40
|
-
|
|
41
|
-
class TestTwoFloors:
|
|
42
|
-
"""with two floors
|
|
43
|
-
|
|
44
|
-
A house with two floor has stairs
|
|
45
|
-
"""
|
|
46
|
-
def test_stairs(self):
|
|
47
|
-
"has stairs"
|
|
48
|
-
assert 1 == 1
|
|
49
|
-
|
|
50
|
-
def test_second_floor(self):
|
|
51
|
-
"has second floor"
|
|
52
|
-
assert 1 == 1
|
|
53
|
-
|
|
54
|
-
def test_third_floor(self):
|
|
55
|
-
"has third floor"
|
|
56
|
-
assert 1 == 2
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
Generates the following output:
|
|
60
|
-
|
|
61
|
-
```
|
|
62
|
-
test/test_sample.py
|
|
63
|
-
|
|
64
|
-
A house
|
|
65
|
-
✓ Has door
|
|
66
|
-
|
|
67
|
-
A house
|
|
68
|
-
With two floors
|
|
69
|
-
✓ Has stairs
|
|
70
|
-
✓ Has second floor
|
|
71
|
-
✗ Has third floor
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
## Installing and running **pySpec**
|
|
75
|
-
|
|
76
|
-
```bash
|
|
77
|
-
pip install pytest-pyspec
|
|
78
|
-
pytest --pyspec
|
|
79
|
-
```
|
|
80
|
-
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
pytest_pyspec/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
pytest_pyspec/item.py,sha256=NI_bDfKILYEZq021Sag8mM1p6wfopjrXOcMeH8rEQuQ,3935
|
|
3
|
-
pytest_pyspec/output.py,sha256=e5qUSfxlf6cseaFimSeCKetcVdAtQaAFxnE00Vy5klM,788
|
|
4
|
-
pytest_pyspec/plugin.py,sha256=qL1Wp8ITvhrNRoUkF-58RejZnsuIbUPYw-kU3B7OFyw,2313
|
|
5
|
-
pytest_pyspec-0.5.3.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
|
6
|
-
pytest_pyspec-0.5.3.dist-info/METADATA,sha256=KNyHdFK7TGx6KITJGOWXqydv-Q-VriweyCVmv68wN38,2248
|
|
7
|
-
pytest_pyspec-0.5.3.dist-info/WHEEL,sha256=kLuE8m1WYU0Ig0_YEGrXyTtiJvKPpLpDEiChiNyei5Y,88
|
|
8
|
-
pytest_pyspec-0.5.3.dist-info/entry_points.txt,sha256=GObsuy5lIVED-9EDmeyFXzvZF3BLoZT7Ll58sTW2pnc,47
|
|
9
|
-
pytest_pyspec-0.5.3.dist-info/RECORD,,
|