Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8c140bc

Browse files
committed
Make sure we test a class with a property
1 parent 7591608 commit 8c140bc

File tree

6 files changed

+70
-2
lines changed

6 files changed

+70
-2
lines changed

sphinx_automodapi/tests/cases/classes_no_inherit/output/api/sphinx_automodapi.tests.example_module.classes.Egg.rst

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,14 @@ Egg
1212

1313

1414

15+
16+
.. rubric:: Attributes Summary
17+
18+
.. autosummary::
19+
20+
~Egg.weight
21+
22+
1523

1624

1725

@@ -29,6 +37,13 @@ Egg
2937

3038

3139

40+
41+
.. rubric:: Attributes Documentation
42+
43+
44+
.. autoattribute:: weight
45+
46+
3247

3348

3449

sphinx_automodapi/tests/cases/classes_with_inherit/output/api/sphinx_automodapi.tests.example_module.classes.Egg.rst

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,14 @@ Egg
1212

1313

1414

15+
16+
.. rubric:: Attributes Summary
17+
18+
.. autosummary::
19+
20+
~Egg.weight
21+
22+
1523

1624

1725

@@ -29,6 +37,13 @@ Egg
2937

3038

3139

40+
41+
.. rubric:: Attributes Documentation
42+
43+
44+
.. autoattribute:: weight
45+
46+
3247

3348

3449

sphinx_automodapi/tests/cases/mixed_toplevel/output/api/sphinx_automodapi.tests.example_module.Egg.rst

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,14 @@ Egg
1212

1313

1414

15+
16+
.. rubric:: Attributes Summary
17+
18+
.. autosummary::
19+
20+
~Egg.weight
21+
22+
1523

1624

1725

@@ -29,6 +37,13 @@ Egg
2937

3038

3139

40+
41+
.. rubric:: Attributes Documentation
42+
43+
44+
.. autoattribute:: weight
45+
46+
3247

3348

3449

@@ -41,4 +56,4 @@ Egg
4156
.. automethod:: eat
4257

4358

44-
59+

sphinx_automodapi/tests/cases/mixed_toplevel_nodiagram/output/api/sphinx_automodapi.tests.example_module.Egg.rst

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,14 @@ Egg
1212

1313

1414

15+
16+
.. rubric:: Attributes Summary
17+
18+
.. autosummary::
19+
20+
~Egg.weight
21+
22+
1523

1624

1725

@@ -29,6 +37,13 @@ Egg
2937

3038

3139

40+
41+
.. rubric:: Attributes Documentation
42+
43+
44+
.. autoattribute:: weight
45+
46+
3247

3348

3449

@@ -41,4 +56,4 @@ Egg
4156
.. automethod:: eat
4257

4358

44-
59+

sphinx_automodapi/tests/cases/mixed_toplevel_nodiagram/output/index.rst.automodapi

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,4 @@ Classes
1717
.. automodsumm:: sphinx_automodapi.tests.example_module
1818
:classes-only:
1919
:toctree: api/
20+

sphinx_automodapi/tests/example_module/classes.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,3 +42,10 @@ def buy(self, price):
4242
Buy some MOAR egg.
4343
"""
4444
pass
45+
46+
@property
47+
def weight(self):
48+
"""
49+
The weight of an egg
50+
"""
51+
return 0

0 commit comments

Comments
 (0)