summary refs log tree commit diff stats
path: root/emacs-lisp/leap/leap-test.el
blob: f6cb5977a5096710616edc0c4aaea5b3c076e8f9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
;;; leap-test.el --- Tests for Leap exercise (exercism)

;;; Commentary:

;;; Code:
(load-file "leap.el")

(ert-deftest vanilla-leap-year ()
  (should (leap-year-p 1996)))

(ert-deftest any-old-year ()
  (should-not (leap-year-p 1997)))

(ert-deftest non-leap-even-year ()
  (should-not (leap-year-p 1997)))

(ert-deftest century ()
  (should-not (leap-year-p 1900)))

(ert-deftest exceptional-century ()
  (should (leap-year-p 2000)))

(provide 'leap-test)
;;; leap-test.el ends here