Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests: Fix ideal value for leap year length in seconds being off #9

Merged
merged 1 commit into from Dec 12, 2020
Merged

Tests: Fix ideal value for leap year length in seconds being off #9

merged 1 commit into from Dec 12, 2020

Conversation

kisaragi-hiu
Copy link
Contributor

ts.el/test/test.el

Lines 445 to 446 in df48734

(should (or (equal 31536000 (floor (ts-difference ts one-year-ago)))
(equal 31622399 (floor (ts-difference ts one-year-ago)))))))

Although the test doesn't take leap seconds into account, a normal leap year should still be 31622400 (60 seconds * 60 minutes * 24 hours * 366 days) seconds long.

Although the test doesn't support leap seconds, a normal leap year
should still be 31622400 seconds.

    (* 60 60 24 366) ;=> 31622400
@Levenson
Copy link

Thanks! Came across with the same issue.

@alphapapa
Copy link
Owner

@kisaragi-hiu Thanks for your patience, and for the fix. I don't know how I made that mistake in the test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants