dirty-equals icon indicating copy to clipboard operation
dirty-equals copied to clipboard

Doing dirty (but extremely useful) things with equals.

Results 24 dirty-equals issues
Sort by recently updated
recently updated
newest added

The following should pass ```py assert '2022-07-15T10:56:38.311Z' == IsNow(delta=10, tz='utc', format_string='%Y-%m-%dT%H:%M:%S.%fZ', enforce_tz=False) ``` (ignoring that that's not "now" any longer obvisouly)

Here's a first go at this. I didn't write too many test cases since most of the Url checking logic is already tested in Pydantic.

I've kept very simple since this is all I'd want to use to save time in tests and imagined I'd probably want to define a custom regex for most other...

Here's a stab at `IsIP`. I'm not sure how useful the `netmask` keyword argument is but thought I'd include it so you can see. Should be easy to take it...

* [x] `IsFalseLike` #23 * [x] `IsTrueLike` #25 * [x] `IsPartialDict` #5 * [x] `IsFullDict(order_matters=False)` #5 * [x] `IsIterable(*items, start=None, finish=None, order_matters=True, len=None)` #7 * [x] `IsList(*items, skip=DontSkip, order_matters=True, len=None)`...

I have a items array, and then the problem is that `_id` is different, but the repr of `price` is not `79`. Should this be supported? ``` E - 'items':...

My use case is pytest with parametrize method. In such situation, IsNow() will compare time generated when pytest will collect tests and now time when tests were run. ```python @pytest.mark.parametrize(...

The following tests fail if the system timezone is not UTC: ``` FAILED tests/test_datetime.py::test_is_datetime[unix-int] - assert 946684800 == IsDatetime(approx=datetime.datetime(2000, 1, 1, 0, 0... FAILED tests/test_datetime.py::test_is_datetime[unix-float] - assert 946684800.123 == IsDatetime(approx=datetime.datetime(2000,...

Approach: * new method on some types, e.g. `__inequality_details__(op)` should return a list of strings * add a utility function to check for `__inequality_details__` and call it if required, *...

Since `float('nan') != float('nan')` we need a custom `FloatNan` type.