tests: compress test_utile_file with test_basic

More code compression/de-duplication.

Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
This commit is contained in:
Alexandru Ardelean
2017-07-10 13:30:49 +03:00
parent ba8625a701
commit 9d47ae824c
2 changed files with 6 additions and 16 deletions

View File

@@ -11,5 +11,9 @@ fi
filename=$(basename "$0")
filename="${filename%.*}"
run_output_test $filename
# This is only for the test_util_file.test ;
# more stuff could be extended
cp -f "$srcdir/valid.json" .
run_output_test $filename "$srcdir"
exit $?

View File

@@ -1,15 +0,0 @@
#!/bin/sh
# Common definitions
if test -z "$srcdir"; then
srcdir="${0%/*}"
test "$srcdir" = "$0" && srcdir=.
test -z "$srcdir" && srcdir=.
fi
. "$srcdir/test-defs.sh"
cp -f "$srcdir/valid.json" .
run_output_test test_util_file "$srcdir"
_err=$?
exit $_err

1
tests/test_util_file.test Symbolic link
View File

@@ -0,0 +1 @@
test_basic.test