Skip to content

Commit 96ca3be

Browse files
committed
DOC: Update documentation for TestCase usage
tm.TestCase no longer follows the nosetest idiom, so it is here to stay, so update the documentation to say that we are using it still. Closes gh-15990.
1 parent 8d63290 commit 96ca3be

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

doc/source/contributing.rst

+1-6
Original file line numberDiff line numberDiff line change
@@ -633,12 +633,7 @@ framework that will facilitate testing and developing. Thus, instead of writing
633633
....
634634
635635
Sometimes, it does make sense to bundle test functions together into a single class, either because the test file is testing multiple functions from a single module, and
636-
using test classes allows for better organization. However, instead of inheriting from ``tm.TestCase``, we should just inherit from ``object``:
637-
638-
.. code-block:: python
639-
640-
class TestReallyCoolFeature(object):
641-
....
636+
using test classes allows for better organization. If test classes are used, make sure that they do inherit from ``tm.TestCase``.
642637

643638
Using ``pytest``
644639
~~~~~~~~~~~~~~~~

pandas/tests/dtypes/test_dtypes.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -356,12 +356,12 @@ def test_construction(self):
356356
def test_construction_generic(self):
357357
# generic
358358
i = IntervalDtype('interval')
359-
assert i.subtype is None
359+
assert (i.subtype is None)
360360
assert is_interval_dtype(i)
361361
assert str(i) == 'interval'
362362

363363
i = IntervalDtype()
364-
assert i.subtype is None
364+
assert (i.subtype is None)
365365
assert is_interval_dtype(i)
366366
assert str(i) == 'interval'
367367

0 commit comments

Comments
 (0)