Skip to content

Commit 4b34b16

Browse files
Lorak-mmkfruch
authored andcommitted
Update README about running unit tests
1 parent 5021f5c commit 4b34b16

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

README-dev.rst

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,11 +95,13 @@ Running Unit Tests
9595
------------------
9696
Unit tests can be run like so::
9797

98-
nosetests -w tests/unit/
98+
python -m pytest --import-mode append tests/unit -k 'not (test_connection_initialization or test_cloud)'
99+
EVENT_LOOP_MANAGER=gevent python -m pytest --import-mode append tests/unit/io/test_geventreactor.py
100+
EVENT_LOOP_MANAGER=eventlet python -m pytest --import-mode append tests/unit/io/test_eventletreactor.py
99101

100102
You can run a specific test method like so::
101103

102-
nosetests -w tests/unit/test_connection.py:ConnectionTest.test_bad_protocol_version
104+
python -m pytest tests/unit/test_connection.py::ConnectionTest::test_bad_protocol_version
103105

104106
Running Integration Tests
105107
-------------------------
@@ -128,11 +130,11 @@ Seeing Test Logs in Real Time
128130
-----------------------------
129131
Sometimes it's useful to output logs for the tests as they run::
130132

131-
nosetests -w tests/unit/ --nocapture --nologcapture
133+
python -m pytest -s tests/unit/
132134

133135
Use tee to capture logs and see them on your terminal::
134136

135-
nosetests -w tests/unit/ --nocapture --nologcapture 2>&1 | tee test.log
137+
python -m pytest -s tests/unit/ 2>&1 | tee test.log
136138

137139
Testing Multiple Python Versions
138140
--------------------------------

0 commit comments

Comments
 (0)