if cpp build disabled, dont run cpp tests anymore

This commit is contained in:
TLINDEN
2015-07-08 01:20:45 +02:00
parent 0be73729ed
commit 4fd1a78a99
3 changed files with 38 additions and 28 deletions

View File

@@ -19,8 +19,13 @@
# You can contact me by mail: <tlinden AT cpan DOT org>.
#
if BUILDCPP
MAYCPP=docpptest
CPPTEST=cpptest
endif
AM_CFLAGS = -I../include/pcp -I../src -I../libpcp/scrypt/crypto
check_PROGRAMS = invalidkeys gencheader statictest cpptest \
check_PROGRAMS = invalidkeys gencheader statictest $(CPPTEST) \
buffertest sample streamtest pipetest decodertest mangle
EXTRA_DIST = Makefile.am Makefile.in *.c *.h *.sh *.pl *.py *.cfg *.cpp \
@@ -62,9 +67,11 @@ invalidkeys_LDADD = ../libpcp/.libs/libpcp1.a \
../src/keyprint.o ../src/keymgmt.o ../src/readpass.o
invalidkeys_SOURCES = invalidkeys.c
if BUILDCPP
AM_CXXFLAGS = -I../include -I../bindings/cpp -I../libpcp/scrypt/crypto
cpptest_LDADD = ../bindings/cpp/.libs/libpcp1++.a ../libpcp/.libs/libpcp1.a
cpptest_SOURCES = cpptest.cpp
endif
#
# Note: some of these unit tests run only on freebsd.
@@ -76,7 +83,7 @@ if BUILDPY
MAYPY=pytest
endif
test: check ctest $(MAYPY)
test: check ctest $(MAYPY) $(MAYCPP)
ctest:
rm -f test* v* stresstest/*
@@ -86,6 +93,9 @@ ctest:
pytest:
./unittests.pl pyunittests.cfg $(CHECK)
docpptest:
./unittests.pl cppunittests.cfg $(CHECK)
stresstest: check
./unittests.pl stresstests.cfg

26
tests/cppunittests.cfg Normal file
View File

@@ -0,0 +1,26 @@
#
# test the c++ api
<test check-cpp-crypto>
cmd = ./cpptest 0
expect = /ok/
</test>
<test check-cpp-vault>
cmd = ./cpptest 1
expect = /ok/
</test>
<test check-cpp-import-pub>
cmd = ./cpptest 2
expect = /ok/
</test>
<test check-cpp-signature>
cmd = ./cpptest 3
expect = /ok/
</test>
<test check-buffer>
cmd = ./cpptest 4
expect = /ok/
</test>

View File

@@ -571,29 +571,3 @@ temporarily disabled
</test>
#
# test the c++ api
<test check-cpp-crypto>
cmd = ./cpptest 0
expect = /ok/
</test>
<test check-cpp-vault>
cmd = ./cpptest 1
expect = /ok/
</test>
<test check-cpp-import-pub>
cmd = ./cpptest 2
expect = /ok/
</test>
<test check-cpp-signature>
cmd = ./cpptest 3
expect = /ok/
</test>
<test check-buffer>
cmd = ./cpptest 4
expect = /ok/
</test>