Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ testtools NEWS

Changes and improvements to testtools_, grouped by release.

2.6.1
2.7.0
~~~~~

Improvements
Expand All @@ -15,6 +15,9 @@ Improvements
* Add typing in various modules (still lacking full coverage).
(Jelmer Vernooij)

* Drop the 'test' command for distutils. This has been
deprecated since 2.6.0. (Jelmer Vernooij)

2.6.0
~~~~~

Expand Down
39 changes: 0 additions & 39 deletions doc/for-test-authors.rst
Original file line number Diff line number Diff line change
Expand Up @@ -88,43 +88,6 @@ of them will happily run testtools tests. In particular:

From now on, we'll assume that you know how to run your tests.

Running test with Distutils
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. deprecated:: 2.6.0

Distutils integration was deprecated in 2.6.0. You should consider
replacing invocations of ``python setup.py test`` with a suitable
alternative such as ``tox``. Refer to `this issue`__ for more information.

.. __: https://github.com/pypa/setuptools/issues/1684

If you are using Distutils_ to build your Python project, you can use the testtools
Distutils_ command to integrate testtools into your Distutils_ workflow::

from distutils.core import setup
from testtools import TestCommand
setup(name='foo',
version='1.0',
py_modules=['foo'],
cmdclass={'test': TestCommand}
)

You can then run::

$ python setup.py test -m exampletest
Tests running...
Ran 2 tests in 0.000s

OK

For more information about the capabilities of the `TestCommand` command see::

$ python setup.py test --help

You can use the `setup configuration`_ to specify the default behavior of the
`TestCommand` command.

Assertions
==========

Expand Down Expand Up @@ -1469,6 +1432,4 @@ Here, ``repr(nullary)`` will be the same as ``repr(f)``.
.. _doctest: http://docs.python.org/library/doctest.html
.. _Deferred: http://twistedmatrix.com/documents/current/core/howto/defer.html
.. _discover: http://pypi.python.org/pypi/discover
.. _Distutils: http://docs.python.org/library/distutils.html
.. _`setup configuration`: http://docs.python.org/distutils/configfile.html
.. _broken: http://chipaca.com/post/3210673069/hasattr-17-less-harmful
10 changes: 0 additions & 10 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
#!/usr/bin/env python
import setuptools

try:
import testtools
cmd_class = {}
if getattr(testtools, 'TestCommand', None) is not None:
cmd_class['test'] = testtools.TestCommand
except:
cmd_class = None


setuptools.setup(
python_requires='>=3.6',
cmdclass=cmd_class,
setup_requires=['pbr'],
pbr=True)
2 changes: 0 additions & 2 deletions testtools/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
'ResourcedToStreamDecorator',
'Tagger',
'TestCase',
'TestCommand',
'TestByTestResult',
'TestResult',
'TestResultDecorator',
Expand Down Expand Up @@ -96,7 +95,6 @@
FixtureSuite,
iterate_tests,
)
from testtools.distutilscmd import TestCommand

# same format as sys.version_info: "A tuple containing the five components of
# the version number: major, minor, micro, releaselevel, and serial. All
Expand Down
74 changes: 0 additions & 74 deletions testtools/distutilscmd.py

This file was deleted.

2 changes: 0 additions & 2 deletions testtools/tests/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ def test_suite():
test_compat,
test_content,
test_content_type,
test_distutilscmd,
test_fixturesupport,
test_helpers,
test_monkey,
Expand All @@ -34,7 +33,6 @@ def test_suite():
test_compat,
test_content,
test_content_type,
test_distutilscmd,
test_fixturesupport,
test_helpers,
test_monkey,
Expand Down
95 changes: 0 additions & 95 deletions testtools/tests/test_distutilscmd.py

This file was deleted.