mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-20 11:40:18 +02:00
* Moved the number related tests from exceptions.test to numbers.test.
This commit is contained in:
parent
049fa4495b
commit
f29b345439
3 changed files with 157 additions and 2 deletions
|
@ -1,3 +1,10 @@
|
|||
2001-03-01 Dirk Herrmann <D.Herrmann@tu-bs.de>
|
||||
|
||||
* exceptions.test, numbers.test: Moved the number related test
|
||||
cases from exceptions.test to numbers.test.
|
||||
|
||||
* numbers.test: Added a test case.
|
||||
|
||||
2001-03-01 Dirk Herrmann <D.Herrmann@tu-bs.de>
|
||||
|
||||
* symbols.test: New file.
|
||||
|
|
|
@ -278,8 +278,6 @@
|
|||
)
|
||||
|
||||
(with-test-prefix "application"
|
||||
(goad x:wrong-type-arg (+ 1 #f))
|
||||
(goad x:wrong-type-arg (+ "1" 2))
|
||||
(goad x:wrong-num-args (let ((x (lambda (a b) (+ a b)))) (x 3)))
|
||||
;; Add more (application) exceptions here.
|
||||
)
|
||||
|
|
|
@ -838,6 +838,46 @@
|
|||
|
||||
)
|
||||
|
||||
;;;
|
||||
;;; lcm
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; number->string
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; string->number
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; number?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; complex?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; real?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; rational?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; integer?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; inexact?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; =
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; <
|
||||
;;;
|
||||
|
@ -1166,3 +1206,113 @@
|
|||
|
||||
(pass-if "n = fixnum-min - 1"
|
||||
(not (< (- fixnum-min 1) (- fixnum-min 1))))))
|
||||
|
||||
;;;
|
||||
;;; >
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; <=
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; >=
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; zero?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; positive?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; negative?
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; max
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; min
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; +
|
||||
;;;
|
||||
|
||||
(with-test-prefix "+"
|
||||
|
||||
(expect-fail "documented?"
|
||||
(documented? +))
|
||||
|
||||
(with-test-prefix "wrong type argument"
|
||||
|
||||
(pass-if-exception "1st argument string"
|
||||
exception:wrong-type-arg
|
||||
(+ "1" 2))
|
||||
|
||||
(pass-if-exception "2nd argument bool"
|
||||
exception:wrong-type-arg
|
||||
(+ 1 #f))))
|
||||
;;;
|
||||
;;; -
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; *
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; /
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; truncate
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; round
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; exact->inexact
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; floor
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; ceiling
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; make-rectangular
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; make-polar
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; real-part
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; imag-part
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; magnitude
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; angle
|
||||
;;;
|
||||
|
||||
;;;
|
||||
;;; inexact->exact
|
||||
;;;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue