mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Merge pull request #8469 from tk0miya/refactor_test_ext_autodoc_slots
refactor: Rename example class
This commit is contained in:
@@ -2,10 +2,6 @@ class Foo:
|
||||
__slots__ = ['attr']
|
||||
|
||||
|
||||
class FooSingleString:
|
||||
__slots__ = 'attr'
|
||||
|
||||
|
||||
class Bar:
|
||||
__slots__ = {'attr1': 'docstring of attr1',
|
||||
'attr2': 'docstring of attr2',
|
||||
@@ -13,3 +9,7 @@ class Bar:
|
||||
|
||||
def __init__(self):
|
||||
self.attr2 = None #: docstring of instance attr2
|
||||
|
||||
|
||||
class Baz:
|
||||
__slots__ = 'attr'
|
||||
|
||||
@@ -1194,6 +1194,14 @@ def test_slots(app):
|
||||
' :module: target.slots',
|
||||
'',
|
||||
'',
|
||||
'.. py:class:: Baz()',
|
||||
' :module: target.slots',
|
||||
'',
|
||||
'',
|
||||
' .. py:attribute:: Baz.attr',
|
||||
' :module: target.slots',
|
||||
'',
|
||||
'',
|
||||
'.. py:class:: Foo()',
|
||||
' :module: target.slots',
|
||||
'',
|
||||
@@ -1201,14 +1209,6 @@ def test_slots(app):
|
||||
' .. py:attribute:: Foo.attr',
|
||||
' :module: target.slots',
|
||||
'',
|
||||
'',
|
||||
'.. py:class:: FooSingleString()',
|
||||
' :module: target.slots',
|
||||
'',
|
||||
'',
|
||||
' .. py:attribute:: FooSingleString.attr',
|
||||
' :module: target.slots',
|
||||
'',
|
||||
]
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user