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.1.tar.gz
(16.5 kB
view hashes)
Built Distribution
Close
Hashes for assertpy_stubs-1.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eeba710345719f63165a5c44e3fa785d5b46e09cbab5c443df57e64575e4986a |
|
MD5 | 40c3e99e45842de6a1e80e04391916e2 |
|
BLAKE2b-256 | 96e50cbc0c8921ce065b402d1f8b323ecc36b487f1d01247e8bdc352e2b6fc64 |