diff options
author | Calvin Morrison <mutantturkey@gmail.com> | 2013-11-13 13:07:23 -0500 |
---|---|---|
committer | Calvin Morrison <mutantturkey@gmail.com> | 2013-11-13 13:07:23 -0500 |
commit | 9066ea884129957fe899d6d10cba1e17547214b9 (patch) | |
tree | aaa3ba9e0e507d9d13d8258def7585675e86f221 /src/nbc/test-library.sml | |
parent | ba07cda9cbf54d33b657d9ee30bc03c0b67f0b5f (diff) |
remove nbc:
Diffstat (limited to 'src/nbc/test-library.sml')
-rw-r--r-- | src/nbc/test-library.sml | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/src/nbc/test-library.sml b/src/nbc/test-library.sml deleted file mode 100644 index 6821e74..0000000 --- a/src/nbc/test-library.sml +++ /dev/null @@ -1,50 +0,0 @@ -signature TEST = sig - type test = - { - description: string - , expectedResult: string - , function: unit -> string - } - val single: test -> unit - val list: test list -> unit -end - -structure Test = struct - fun single {description, expectedResult, function} = - let - val actualResult = function () - in - if expectedResult = actualResult then - TextIO.output ( - TextIO.stdErr - , ( - description - ^ " succeeded.\n" - ) - ) - else ( - TextIO.output ( - TextIO.stdErr - , ( - description - ^ " was supposed to be " - ^ expectedResult - ^ ", but was actually " - ^ actualResult - ^ ".\n" - ) - ); OS.Process.exit OS.Process.failure - ) - end handle exception' => ( - TextIO.output ( - TextIO.stdErr - , ( - description - ^ " failed with exception " - ^ exnMessage exception' - ^ ".\n" - ) - ); OS.Process.exit OS.Process.failure - ) - fun list tests = app single tests -end |