Refactor the test system
[jansson.git] / test / suites / api / run
1 #!/bin/sh
2 #
3 # Copyright (c) 2009 Petri Lehtinen <petri@digip.org>
4 #
5 # Jansson is free software; you can redistribute it and/or modify
6 # it under the terms of the MIT license. See LICENSE for details.
7
8 is_test() {
9     test "${test_name%.c}" != "$test_name"
10 }
11
12 run_test() {
13     $suite_builddir/${test_name%.c} >$test_log/stdout 2>$test_log/stderr
14 }
15
16 show_error() {
17     valgrind_show_error && return
18     cat $test_log/stderr
19 }
20
21 . $top_srcdir/test/scripts/run-tests.sh