You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tests/README.md
+14-14
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,20 @@ objects at runtime.
17
17
in the `tests` and `scripts` directories.
18
18
19
19
To run the tests, follow the [setup instructions](../CONTRIBUTING.md#preparing-the-environment)
20
-
in the `CONTRIBUTING.md` document. In particular, we recommend running with Python 3.9+.
20
+
in the `CONTRIBUTING.md` document. In particular, you have to run with Python 3.9+.
21
+
22
+
In order for `pytype_test` and `pyright_test` to work correctly, some third-party stubs
23
+
may require extra dependencies external to typeshed to be installed in your virtual environment
24
+
prior to running the test.
25
+
You can list or install all of a stubs package's external dependencies using the following script:
26
+
```bash
27
+
(.venv3)$ python tests/get_external_stub_requirements.py <third_party_stub># List external dependencies for <third_party_stub>
28
+
(.venv3)$ python tests/get_external_stub_requirements.py <third_party_stub1><third_party_stub2># List external dependencies for <third_party_stub1> and <third_party_stub2>
29
+
(.venv3)$ python tests/get_external_stub_requirements.py # List external dependencies for all third-party stubs in typeshed
30
+
# Install external dependencies for all third-party stubs in typeshed
(.venv3)$ if [ -n"$DEPENDENCIES" ];then pip install $DEPENDENCIES;fi
33
+
```
21
34
22
35
## Run all tests for a specific stub
23
36
@@ -78,19 +91,6 @@ checks that would typically fail on incomplete stubs (such as `Unknown` checks).
78
91
In typeshed's CI, pyright is run with these configuration settings on a subset of
79
92
the stubs in typeshed (including the standard library).
80
93
81
-
In order for `pyright_test` to work correctly, some third-party stubs may require
82
-
dependencies external to typeshed to be installed in your virtual environment
83
-
prior to running the test.
84
-
You can list or install all of a stubs package's external dependencies using the following script:
85
-
```bash
86
-
(.venv3)$ python tests/get_external_stub_requirements.py <third_party_stub># List external dependencies for <third_party_stub>
87
-
(.venv3)$ python tests/get_external_stub_requirements.py <third_party_stub1><third_party_stub2># List external dependencies for <third_party_stub1> and <third_party_stub2>
88
-
(.venv3)$ python tests/get_external_stub_requirements.py # List external dependencies for all third-party stubs in typeshed
89
-
# Install external dependencies for all third-party stubs in typeshed
0 commit comments