Skip to content

Commit

Permalink
More wordsmithing
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexWaygood committed Apr 19, 2022
1 parent 8d3db2c commit 632a75f
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions test_cases/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ pass a type checker without error.

The internal structure of this directory should mimic typeshed as a whole.
However, unlike the rest of typeshed, this directory largely contains `.py`
files, because the purpose of this folder is to test the implications of
typeshed changes for end-users. For example, the stub for `builtins.pow` is
files. This is because the purpose of this folder is to test the implications
of typeshed changes for end users. For example, the stub for `builtins.pow` is
found in `stdlib/builtins.pyi`, and the regression tests for `pow` are found in
`test_cases/stdlib/test_builtins.py`.

100% test coverage for typeshed is neither necessary nor desirable, as it would
lead to unnecessary code duplication, and we have multiple other mechanisms for
spotting errors in the stubs. As such, this directory should only contain tests
for functions and classes which are known to have caused problems in the past,
and are difficult to get right.
lead to unnecessary code duplication. Moreover, typeshed has multiple other
mechanisms for spotting errors in the stubs. As such, this directory should
only contain tests for functions and classes which are known to have caused
problems in the past, where the stubs are difficult to get right.

Note that, unlike elsewhere in typeshed, the test cases in this directory
cannot always use modern syntax for type hints. For example, PEP 604 syntax
Expand Down

0 comments on commit 632a75f

Please sign in to comment.