summaryrefslogtreecommitdiff
path: root/iterative-add/iterative-add-test.scm
blob: d31857066f73da8b32cac016a9497f7d9d71db15 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
;; -*- compile-command: "guile -L . iterative-add-test.scm"; -*-
(use-modules (srfi srfi-64)
	     (iterative-add))


(test-begin "harness")

(test-equal "add 0 to 1"
  1
  (iterative-add-generator 1))

(test-equal "add 1 to 2"
  3
  (iterative-add-generator 2))

(test-equal "add 2 to 6"
  8
  (iterative-add-generator 6))

(test-end "harness")