summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKjell Ahlstedt <kjell.ahlstedt@bredband.net>2016-12-11 16:05:27 +0100
committerKjell Ahlstedt <kjell.ahlstedt@bredband.net>2016-12-11 16:05:27 +0100
commit9c9a73fa7bbf200f414979d194fc8636f060be3f (patch)
tree537b4287208240e438f58a619477a95921c86f53
parent404a79cb246c723fc64e6a0f9316afbbcf7c7844 (diff)
downloadsigc++-9c9a73fa7bbf200f414979d194fc8636f060be3f.tar.gz
Add tests/memleakcheck.sh
This shell script runs the test cases with valgrind, searching for memory leaks. Bug 775871
-rwxr-xr-xtests/memleakcheck.sh23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/memleakcheck.sh b/tests/memleakcheck.sh
new file mode 100755
index 0000000..07a7311
--- /dev/null
+++ b/tests/memleakcheck.sh
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+# Run all libsigc++ tests with valgrind, searching for memory leaks.
+# Execute this script in the tests directory.
+# valgrind --leak-check=full .libs/lt-test_*
+
+for testprog in test_accum_iter test_accumulated test_bind test_bind_as_slot \
+ test_bind_ref test_bind_refptr test_bind_return test_compose \
+ test_copy_invalid_slot test_cpp11_lambda test_custom test_disconnect \
+ test_disconnect_during_emit test_exception_catch test_hide \
+ test_limit_reference test_member_method_trait test_mem_fun test_ptr_fun \
+ test_retype test_retype_return test_signal test_signal_move test_size \
+ test_slot test_slot_disconnect test_slot_move test_trackable \
+ test_trackable_move test_track_obj test_tuple_cdr test_tuple_end \
+ test_tuple_for_each test_tuple_start test_tuple_transform_each \
+ test_visit_each test_visit_each_trackable test_weak_raw_ptr
+do
+ echo ================
+ echo === $testprog
+ echo ================
+ valgrind --leak-check=full .libs/lt-$testprog
+done
+