From: kaoru Date: Sat, 21 Feb 2004 19:38:25 +0000 (+0000) Subject: * test-elmo-util.el (test-elmo-number-set-member-1): Use `equal'. X-Git-Tag: wl-2_11_25~46 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=6e290fc8c57e86711b139a836ff56971e3dd9b34;p=elisp%2Fwanderlust.git * test-elmo-util.el (test-elmo-number-set-member-1): Use `equal'. (test-elmo-number-set-member-2): New testcase. --- diff --git a/tests/ChangeLog b/tests/ChangeLog index 847ca1d..a1ac941 100644 --- a/tests/ChangeLog +++ b/tests/ChangeLog @@ -1,3 +1,8 @@ +2004-02-21 TAKAHASHI Kaoru + + * test-elmo-util.el (test-elmo-number-set-member-1): Use `equal'. + (test-elmo-number-set-member-2): New testcase. + 2004-02-19 TAKAHASHI Kaoru * test-elmo-util.el (lunit-test-case-setup): Set `print-length', diff --git a/tests/test-elmo-util.el b/tests/test-elmo-util.el index d9d0aa5..81f30f9 100644 --- a/tests/test-elmo-util.el +++ b/tests/test-elmo-util.el @@ -1,22 +1,16 @@ (require 'lunit) (require 'elmo-util) - (luna-define-class test-elmo-util (lunit-test-case)) ;; setup & teardown (defvar test-elmo-temoporary-file) (luna-define-method lunit-test-case-setup ((case test-elmo-util)) - (setq print-length 1 - print-level 1) - (setq case-fold-search nil) (setq test-elmo-temoporary-file (make-temp-file temporary-file-directory))) (luna-define-method lunit-test-case-teardown ((case test-elmo-util)) - (setq print-length nil - print-level nil) (when (file-exists-p test-elmo-temoporary-file) (delete-file test-elmo-temoporary-file))) @@ -190,15 +184,20 @@ (elmo-flatten '(1 2 (3 4 5)))))) (luna-define-method test-elmo-number-set-member-1 ((case test-elmo-util)) - "Check edge" + "Check edge." (lunit-assert - (elmo-number-set-member 1 '((1 . 99)))) + (equal '((1 . 99)) + (elmo-number-set-member 1 '((1 . 99))))) (lunit-assert - (elmo-number-set-member 99 '((1 . 99)))) + (equal '((1 . 99)) + (elmo-number-set-member 99 '((1 . 99)))))) + +(luna-define-method test-elmo-number-set-member-2 ((case test-elmo-util)) + "Check edge." (lunit-assert - (not (elmo-number-set-member 0 '((1 . 99))))) + (null (elmo-number-set-member 0 '((1 . 99))))) (lunit-assert - (not (elmo-number-set-member 100 '((1 . 99)))))) + (null (elmo-number-set-member 100 '((1 . 99)))))) (luna-define-method test-elmo-number-set-append-list-1 ((case test-elmo-util)) "Simple testcase."