diff options
author | Joshua Haberman <jhaberman@gmail.com> | 2011-12-22 12:15:45 -0800 |
---|---|---|
committer | Joshua Haberman <jhaberman@gmail.com> | 2011-12-22 12:15:45 -0800 |
commit | 1b9b6bd1ad2d862a7df86096e96991135f0fb92c (patch) | |
tree | b1023a383c22b4ce52e33d114da8cbe1bffcbd79 /Makefile | |
parent | 1bcab1377de6afe8c0f9c895cdba04baacf3e4a5 (diff) |
Fixed the open-source build.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 28 |
1 files changed, 16 insertions, 12 deletions
@@ -199,12 +199,10 @@ SIMPLE_TESTS= \ tests/test_varint \ tests/tests \ -INTERACTIVE_TESTS= \ +# Too many tests in this binary to run Valgrind (it takes minutes). +SLOW_TESTS= \ tests/test_decoder \ -# tests/test_stream \ - - SIMPLE_CXX_TESTS= \ tests/test_table \ tests/test_cpp \ @@ -214,9 +212,7 @@ VARIADIC_TESTS= \ tests/t.test_vs_proto2.googlemessage2 \ TESTS=$(SIMPLE_TESTS) $(SIMPLE_CXX_TESTS) $(VARIADIC_TESTS) - - -tests: $(TESTS) $(INTERACTIVE_TESTS) +tests: $(TESTS) $(TESTS): $(LIBUPB) tests/tests: tests/test.proto.pb @@ -228,13 +224,21 @@ VALGRIND=valgrind --leak-check=full --error-exitcode=1 test: tests @echo Running all tests under valgrind. @set -e # Abort on error. - @for test in $(TESTS); do \ + @for test in $(SIMPLE_TESTS) $(SIMPLE_CXX_TESTS); do \ + if [ -x ./$$test ] ; then \ + echo !!! $(VALGRIND) ./$$test tests/test.proto.pb; \ + $(VALGRIND) ./$$test tests/test.proto.pb || exit 1; \ + fi \ + done; + @for test in "$(SLOW_TESTS)"; do \ if [ -x ./$$test ] ; then \ - echo !!! $(VALGRIND) ./$$test; \ - $(VALGRIND) ./$$test || exit 1; \ + echo !!! ./$$test; \ + ./$$test || exit 1; \ fi \ - done; \ - echo "All tests passed!" + done; + @$(VALGRIND) tests/t.test_vs_proto2.googlemessage1 benchmarks/google_messages.proto.pb benchmarks/google_message1.dat + @$(VALGRIND) tests/t.test_vs_proto2.googlemessage2 benchmarks/google_messages.proto.pb benchmarks/google_message2.dat + @echo "All tests passed!" tests/t.test_vs_proto2.googlemessage1 \ tests/t.test_vs_proto2.googlemessage2: \ |