aboutsummaryrefslogtreecommitdiff
path: root/tests/run-tests.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2019-04-03 22:21:20 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2019-04-03 22:24:45 +0200
commitc286ee7d410950152177d209c20a843d4a3f8c26 (patch)
treee373e3b04b5b47f21be504fcad65a498a28dc5c7 /tests/run-tests.scm
parentAdd parser for BYDAY RRULE's. (diff)
downloadcalp-c286ee7d410950152177d209c20a843d4a3f8c26.tar.gz
calp-c286ee7d410950152177d209c20a843d4a3f8c26.tar.xz
Update tests.
Diffstat (limited to 'tests/run-tests.scm')
-rwxr-xr-xtests/run-tests.scm37
1 files changed, 37 insertions, 0 deletions
diff --git a/tests/run-tests.scm b/tests/run-tests.scm
new file mode 100755
index 00000000..e68f058b
--- /dev/null
+++ b/tests/run-tests.scm
@@ -0,0 +1,37 @@
+#!/usr/bin/guile \
+-s
+!#
+
+(eval-when (compile load)
+ (define here (dirname (current-filename))))
+
+(add-to-load-path (format #f "~a/module"
+ (dirname here)))
+
+
+(use-modules (ice-9 ftw)
+ (ice-9 sandbox))
+
+(define files
+ (scandir here
+ (lambda (name)
+ (and (< 2 (string-length name))
+ (not (string=? name (basename (current-filename))))
+ (string=? "scm" (string-take-right name 3))))))
+
+(setenv "TESTPATH"
+ (format #f "~a/testdata" (dirname here)))
+
+(use-modules (srfi srfi-64))
+
+;; Load tests
+
+(add-to-load-path here)
+(for-each load-from-path files)
+
+;; Final test, triggers output
+(test-begin "metatest")
+(test-assert #t)
+(test-expect-fail 1)
+(test-assert #f)
+(test-end "metatest")