add test target

This commit is contained in:
Valient Gough 2015-06-15 23:11:50 -07:00
parent f04381fe17
commit 12e8efb2cd
3 changed files with 16 additions and 4 deletions

View File

@ -3,4 +3,4 @@ script:
- sh devmode
- cd build
- make
- ./checkops
- make test

View File

@ -158,3 +158,18 @@ if (GETTEXT_FOUND)
gettext_process_po_files(${lang} ALL PO_FILES ${pofile})
endforeach()
endif (GETTEXT_FOUND)
# Tests
enable_testing()
add_test (NAME checkops
COMMAND checkops)
find_program (PERL_PROGRAM perl)
if (PERL_PROGRAM)
file(GLOB pl_test_files "tests/*.t.pl")
#add_test (NAME scriptedtests
# COMMAND ${PERL_PROGRAM} -I ${CMAKE_SOURCE_DIR}
# -MTest::Harness
# -e "$$Test::Harness::verbose=1; runtests @ARGV;"
# ${pl_test_files})
endif (PERL_PROGRAM)

View File

@ -12,9 +12,6 @@ require("tests/common.pl");
my $tempDir = $ENV{'TMPDIR'} || "/tmp";
# run unit tests
ok( system("./encfs/test 2> /dev/null") == 0, "unit tests");
# test filesystem in standard config mode
&runTests('standard');