@@ -137,7 +137,10 @@ If you want to run the pyright tests, you need to have
137137### mypy_test.py
138138
139139This test requires Python 3.6 or higher; Python 3.6.1 or higher is recommended.
140- Run using:` (.venv3)$ python3 tests/mypy_test.py `
140+ Run using:
141+ ```
142+ (.venv3)$ python3 tests/mypy_test.py
143+ ```
141144
142145This test is shallow — it verifies that all stubs can be
143146imported but doesn't check whether stubs match their implementation
@@ -161,7 +164,10 @@ running mypy --python-version 3.9 --strict-optional # with 342 files
161164This test requires Python 2.7 and Python 3.6. Pytype will
162165find these automatically if they're in ` PATH ` , but otherwise you must point to
163166them with the ` --python27-exe ` and ` --python36-exe ` arguments, respectively.
164- Run using: ` (.venv3)$ python3 tests/pytype_test.py `
167+ Run using:
168+ ```
169+ (.venv3)$ python3 tests/pytype_test.py
170+ ```
165171
166172This test works similarly to ` mypy_test.py ` , except it uses ` pytype ` .
167173
@@ -172,27 +178,39 @@ This test requires Node.js to be installed.
172178### mypy_self_check.py
173179
174180This test requires Python 3.6 or higher; Python 3.6.1 or higher is recommended.
175- Run using: ` (.venv3)$ python3 tests/mypy_self_check.py `
181+ Run using:
182+ ```
183+ (.venv3)$ python3 tests/mypy_self_check.py
184+ ```
176185
177186This test checks mypy's code base using mypy and typeshed code in this repo.
178187
179188### mypy_test_suite.py
180189
181190This test requires Python 3.5 or higher; Python 3.6.1 or higher is recommended.
182- Run using: ` (.venv3)$ python3 tests/mypy_test_suite.py `
191+ Run using:
192+ ```
193+ (.venv3)$ python3 tests/mypy_test_suite.py
194+ ```
183195
184196This test runs mypy's own test suite using the typeshed code in your repo. This
185197will sometimes catch issues with incorrectly typed stubs, but is much slower
186198than the other tests.
187199
188200### check_consistent.py
189201
190- Run using: ` python3 tests/check_consistent.py `
202+ Run using:
203+ ```
204+ python3 tests/check_consistent.py
205+ ```
191206
192207### stubtest_test.py
193208
194209This test requires Python 3.6 or higher.
195- Run using ` (.venv3)$ python3 tests/stubtest_test.py `
210+ Run using
211+ ```
212+ (.venv3)$ python3 tests/stubtest_test.py
213+ ```
196214
197215This test compares the stdlib stubs against the objects at runtime. Because of
198216this, the output depends on which version of Python and on what kind of system
@@ -209,13 +227,20 @@ can add to the whitelists for each affected Python version in
209227at [ mypy] ( https://github.com/python/mypy/issues ) .
210228
211229To run stubtest against third party stubs, it's easiest to use stubtest
212- directly, with `(.venv3)$ python3 -m mypy.stubtest --custom-typeshed-dir
213- <path-to-typeshed > <third-party-module >`.
230+ directly, with
231+ ```
232+ (.venv3)$ python3 -m mypy.stubtest \
233+ --custom-typeshed-dir <path-to-typeshed> \
234+ <third-party-module>
235+ ```
214236stubtest can also help you find things missing from the stubs.
215237
216238
217239### flake8
218240
219- flake8 requires Python 3.6 or higher. Run using: ` (.venv3)$ flake8 `
241+ flake8 requires Python 3.6 or higher. Run using:
242+ ```
243+ (.venv3)$ flake8
244+ ```
220245
221246Note typeshed uses the ` flake8-pyi ` and ` flake8-bugbear ` plugins.
0 commit comments