1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-30 06:50:31 +02:00

Test cases for `version-matches?'.

* test-suite/tests/modules.test ("module versions"): New tests for
  `version-matches?'.
This commit is contained in:
Julian Graham 2010-05-02 14:58:15 -04:00
parent ff6182edfc
commit e96bac4523

View file

@ -330,3 +330,22 @@
(current-module))) (current-module)))
(lambda (key . args) (lambda (key . args)
#f)))) #f))))
;;;
;;; R6RS compatibility
;;;
(with-test-prefix "module versions"
(pass-if "version-matches? for matching versions"
(version-matches? '(1 2 3) '(1 2 3)))
(pass-if "version-matches? for non-matching versions"
(not (version-matches? '(3 2 1) '(1 2 3))))
(pass-if "version-matches? against more specified version"
(version-matches? '(1 2) '(1 2 3)))
(pass-if "version-matches? against less specified version"
(not (version-matches? '(1 2 3) '(1 2)))))