Mypy|Pyright plugin and stubs for assertpy
Project description
assertpy-stubs
Add types for assertpy for mypy or pyright.
Installation
$ pip install assertpy-stubs
Usage
Mypy or pyright will automatically use the type annotations in this package, once it is installed. You just need to annotate your code:
from assertpy import assert_that
def test_something():
assert_that(1 + 2).is_equal_to(3)
assert_that("foobar").is_length(6).starts_with("foo").ends_with("bar")
assert_that(["a", "b", "c"]).contains("a").does_not_contain("x")
For general hints how to use type annotations, please read Type Annotations in Python 3.8
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
assertpy_stubs-1.1.2.tar.gz
(16.1 kB
view hashes)
Built Distribution
Close
Hashes for assertpy_stubs-1.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3cfff48f5953ab78908d7f899d788ffb1371d50f8d7d7cbea0db17cabd03b6c5 |
|
MD5 | b5bf660737c99b6b2490d4278eb16447 |
|
BLAKE2b-256 | 75b06242328172653f7b6d3dedc520cd41319fdbcb8126494aa6934955bb0a27 |