assertions in __eq__methods
Project description
assertions in __eq__ methods.
>>> from eqassertions import Any, NotNone, IsA, IsTrue, Match >>> data = {"a": 1, "b": 2} >>> assert {"a": 1, "b": Any()} >>> assert {"a": 1, "b": NotNone()} >>> assert {"a": 1, "b": IsA(int)} >>> assert {"a": 1, "b": IsTrue()} >>> assert v == {"a": 1, "b": Match(r"\d")} >>> assert v == {"a": 1, "b": Match(r"[a-z]")} Traceback (most recent call last): ... AssertionError
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
eqassertions-0.3.tar.gz
(1.5 kB
view details)
Built Distribution
File details
Details for the file eqassertions-0.3.tar.gz
.
File metadata
- Download URL: eqassertions-0.3.tar.gz
- Upload date:
- Size: 1.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fe80b05d4635fe6bf60fd58198bb626f51b20160615b091411e42668ea2a8c65 |
|
MD5 | f3c189f6c8f6b4b58e4b473dd8858fdc |
|
BLAKE2b-256 | 98b7fceb002dcc6d1626b61ec0dc0ef5521dfce83953084e9528f8ea2d322dac |
File details
Details for the file eqassertions-0.3-py3-none-any.whl
.
File metadata
- Download URL: eqassertions-0.3-py3-none-any.whl
- Upload date:
- Size: 2.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 62dfb357c95fd5bcfe5ee0fe9e317745bbef5d7a2e270c07af72cde3eb543107 |
|
MD5 | 16dfadf970b3737daed92ccfed375144 |
|
BLAKE2b-256 | 1c93ced25038bc42f9535986546fd2ebc5dfff1935326d5e2562cb7600d7810b |