;; -*-theme-d-*-

;; Copyright (C) 2018  Tommi Höynälänmaa
;; Distributed under GNU General Public License version 3,
;; see file doc/GPL-3.

;; Expected results: translation and running OK

(define-proper-program (tests test671)

  (import (standard-library core)
	  (standard-library math)
	  (standard-library console-io)
	  (tests numerical-test-env))

  (define-simple-proc main (() <none> nonpure)
    (report-test (+ 1 2) 3)
    (report-test (+ 1 2.5) 3.5)
    (report-test (+ 1.5 2) 3.5)
    (report-test (+ 1.5 2.5) 4.0)
    (report-test (- 1 2) -1)
    (report-test (- 1 2.5) -1.5)
    (report-test (- 1.5 2) -0.5)
    (report-test (- 1.5 2.5) -1.0)
    (report-test (* 1 2) 2)
    (report-test (* 1 2.5) 2.5)
    (report-test (* 1.5 2) 3.0)
    (report-test (* 1.5 2.5) 3.75)
    (report-test (/ 1 2) (rational 1 2))
    (report-test (/ 1 2.5) 0.4)
    (report-test (/ 1.5 2) 0.75)
    (report-test (/ 1.5 2.5) 0.6)
    (report-test (- 1) -1)
    (report-test (- 1.5) -1.5)))
