Andrei Prigorshnev
c5c043d9e2
DEV: support nil values in the eq_time matcher ( #22116 )
...
We use it like this:
expect(message.created_at).to eq_time(created_at)
The problem is that if one of the values or both of them are `nil` the matcher fails
with this error:
NoMethodError: undefined method `-' for nil:NilClass
This commit adds support for `nil` values. If both time values are `nil` they are equal,
if only one value is `nil` they aren't.
2023-06-20 19:06:40 +04:00
..
2023-01-09 11:49:28 +00:00
2023-03-08 10:39:12 +10:00
2023-01-09 11:49:28 +00:00
2023-02-21 10:30:48 +01:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-06-20 09:49:22 +08:00
2023-06-13 14:21:46 -03:00
2022-12-19 13:46:17 +10:00
2022-10-12 20:25:49 +02:00
2023-01-09 11:49:28 +00:00
2021-10-19 17:12:29 +05:30
2023-03-08 11:26:32 +08:00
2023-06-12 13:59:54 +02:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2022-11-01 16:33:17 +00:00
2022-07-26 10:34:15 +02:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-05-25 07:53:57 +08:00
2023-01-09 11:49:28 +00:00
2023-06-13 11:47:21 +02:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-05-25 07:53:57 +08:00
2023-06-19 10:58:36 +08:00
2023-01-09 11:49:28 +00:00
2023-06-20 19:06:40 +04:00
2023-01-09 11:49:28 +00:00
2023-02-03 09:55:28 +11:00
2023-01-09 11:49:28 +00:00
2023-01-20 09:50:24 +08:00
2023-01-09 11:49:28 +00:00