Pattern matching helper classes designed to be similar to Jest expect matchers, but modified to suit a Pythonic style of programming.
Project description
Jestspectation
Pattern matching helper classes designed to be similar to Jest's expect matchers, but modified to suit a Pythonic style of programming.
Basic Usage
import jestspectation as expect
assert {
"a": 1,
"b": 2,
"c": 3,
} == {
"a": 1,
"b": expect.Any(int),
"c": expect.FloatApprox(2.5, magnitude=0.5)
}
Installation
pip install jestspectation
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
Jestspectation-0.2.0.tar.gz
(5.2 kB
view hashes)
Built Distribution
Close
Hashes for Jestspectation-0.2.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c2dcdfb3a3c9ca31c8117f47070f28944ce8d28ac0bdc4faeb8aae5b0af217da |
|
MD5 | 74059ac2e2ff90ae28cab1344d955306 |
|
BLAKE2b-256 | 222b50c9dde7c8263e79af4d758239ac48ac596e7961335afb5279d8d6fe46a4 |