]> git.draconx.ca Git - liblbx.git/blobdiff - testsuite.at
Port all test cases to Autotest.
[liblbx.git] / testsuite.at
old mode 100755 (executable)
new mode 100644 (file)
similarity index 54%
rename from tests/empty-image.tap
rename to testsuite.at
index c506eb5..63373f0
@@ -1,8 +1,4 @@
-#!/bin/sh
-#
-# 2ooM: The Master of Orion II Reverse Engineering Project
-# Test decoding of empty (0x0) images
-# Copyright © 2013 Nick Bowler
+AT_COPYRIGHT([Copyright © 2021 Nick Bowler])
 #
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
 # GNU General Public License for more details.
 #
 # You should have received a copy of the GNU General Public License
-# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+# along with this program.  If not, see <https://www.gnu.org/licenses/>.
 
-. "$srcdir/tests/util/test-init.sh" || exit 99
+AT_INIT
+AT_COLOR_TESTS
 
-plan_ 2
-dx_create_testdir
+AT_TESTED([lbxtool lbximg])
 
-command_ok_ "decoding image-0x0" $LBXIMG -F pbm -dnf "$testdata/image-0x0"
+m4_divert_push([PREPARE_TESTS])dnl
+: "${ASAN_OPTIONS=detect_leaks=0}"
+export ASAN_OPTIONS
+: "${testdata=$top_srcdir/tests/testdata}"
+m4_divert_pop([PREPARE_TESTS])
 
-check_output() {
-       diff out.000.pbm - 1>&2 <<'EOF'
-P1
-0 0
-EOF
-}
-command_ok_ "empty (0x0) image output" check_output
+m4_include([tests/archives.at])
+m4_include([tests/images.at])
+m4_include([tests/moo2data.at])