aboutsummaryrefslogtreecommitdiff
path: root/tests/do_tests
diff options
context:
space:
mode:
authorToni Uhlig <matzeton@googlemail.com>2020-12-01 13:33:34 +0100
committerToni Uhlig <matzeton@googlemail.com>2020-12-01 13:33:34 +0100
commitc8bf38e5fb717d40635a2a89b22ed71b0de4266b (patch)
tree63751b2f5497c6f99e1c6a78f23a8e6e5c49833f /tests/do_tests
Squashed 'dependencies/uthash/' content from commit 8e67ced
git-subtree-dir: dependencies/uthash git-subtree-split: 8e67ced1d1c5bd8141c542a22630e6de78aa6b90
Diffstat (limited to 'tests/do_tests')
-rwxr-xr-xtests/do_tests21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/do_tests b/tests/do_tests
new file mode 100755
index 000000000..574403f2d
--- /dev/null
+++ b/tests/do_tests
@@ -0,0 +1,21 @@
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+my @tests;
+for (glob "test*[0-9]") {
+ push @tests, $_ if -e "$_.ans";
+}
+
+my $num_failed=0;
+
+for my $test (@tests) {
+ `./$test > $test.out`;
+ `diff $test.out $test.ans`;
+ print "$test failed\n" if $?;
+ $num_failed++ if $?;
+}
+
+print scalar @tests . " tests conducted, $num_failed failed.\n";
+exit $num_failed;