From: kaoru Date: Wed, 12 Dec 2001 06:43:58 +0000 (+0000) Subject: * test-dist.el (test-codename, test-version-wl-changelog) X-Git-Tag: wl-2_8-root~21 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=0516dffcb65f99893e9474796619c4e249aecf13;hp=5ad375c41b2bc6987c19a0e95bd30cb92f13eb42;p=elisp%2Fwanderlust.git * test-dist.el (test-codename, test-version-wl-changelog) (test-version-elmo-changelog, test-version-toplevel-changelog) : New testcases. --- diff --git a/tests/test-dist.el b/tests/test-dist.el index 28ef908..c9b62d4 100644 --- a/tests/test-dist.el +++ b/tests/test-dist.el @@ -92,3 +92,48 @@ (insert-file-contents (expand-file-name "wl-refcard.tex" DOCDIR)) (re-search-forward "^\\\\def\\\\versionnumber{\\([0-9\.]+\\)}$") (match-string 1))))) + +;; wl/ChangeLog +(luna-define-method test-version-wl-changelog ((case test-dist)) + (require 'wl-version) + (lunit-assert + (string= + (product-version-string (product-find 'wl-version)) + (with-temp-buffer + (insert-file-contents (expand-file-name "ChangeLog" WLDIR)) + (re-search-forward + "^\t\\* Version number is increased to \\([0-9\\.]+[0-9]\\).$") + (match-string 1))))) + +;; elmo/ChangeLog +(luna-define-method test-version-elmo-changelog ((case test-dist)) + (require 'elmo-version) + (lunit-assert + (string= + (product-version-string (product-find 'elmo-version)) + (with-temp-buffer + (insert-file-contents (expand-file-name "ChangeLog" ELMODIR)) + (re-search-forward + "^\t\\* elmo-version.el (elmo-version): Up to \\([0-9\\.]+[0-9]\\).$") + (match-string 1))))) + +;; ChangeLog (toplevel) +(luna-define-method test-version-toplevel-changelog ((case test-dist)) + (require 'wl-version) + (when (and (string= (wl-version-status) "stable") + ;; pre release version don't check. + (not (string-match + "pre" + (product-code-name (product-find 'wl-version))))) + (with-temp-buffer + (insert-file-contents (expand-file-name "ChangeLog" "./")) + (re-search-forward + "\\* \\([0-9\\.]+\\) - \"\\([^\"]+\\)\".$") + (lunit-assert + (string= + (product-version-string (product-find 'wl-version)) + (match-string 1))) + (lunit-assert + (string= + (product-code-name (product-find 'wl-version)) + (match-string 2))))))