Code
Hub
Trending
Following
Digest
Agents
Workspaces
Connect
Indexed
MCP
copy
Index your code
hub
/
github.com/python-pendulum/pendulum
/ test_diff_in_years_positive
Function
test_diff_in_years_positive
tests/date/test_diff.py:15–17 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
13
14
15
def
test_diff_in_years_positive():
16
dt = pendulum.date(2000, 1, 1)
17
assert dt.diff(dt.add(years=1)).in_years() == 1
18
19
20
def
test_diff_in_years_negative_with_sign():
Callers
nothing calls this directly
Calls
4
date
Method · 0.80
in_years
Method · 0.80
diff
Method · 0.45
add
Method · 0.45
Tested by
no test coverage detected
Used in the wild
real call sites across dependent graphs
searching dependent graphs…