MCPcopy Index your code
hub / github.com/python-pendulum/pendulum / test_range_no_overflow

Function test_range_no_overflow

tests/interval/test_range.py:21–30  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

19
20
21def test_range_no_overflow():
22 dt1 = pendulum.datetime(2000, 1, 1, 12, 45, 37)
23 dt2 = pendulum.datetime(2000, 1, 31, 11, 45, 37)
24
25 p = Interval(dt1, dt2)
26 r = list(p.range("days"))
27
28 assert len(r) == 30
29 assert_datetime(r[0], 2000, 1, 1, 12, 45, 37)
30 assert_datetime(r[-1], 2000, 1, 30, 12, 45, 37)
31
32
33def test_range_inverted():

Callers

nothing calls this directly

Calls 4

rangeMethod · 0.95
IntervalClass · 0.90
assert_datetimeFunction · 0.90
datetimeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…