[Telepathy-commits] [telepathy-salut/master] Tests: refdbg: fix README and let the user use a different refdbg

Alban Crequy alban.crequy at collabora.co.uk
Wed Oct 29 05:33:38 PDT 2008


---
 tests/README                            |    9 ++++++---
 tests/twisted/tools/exec-with-log.sh.in |    7 +++++++
 2 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/tests/README b/tests/README
index 1e71909..5e5d329 100644
--- a/tests/README
+++ b/tests/README
@@ -41,11 +41,14 @@ To debug an individual test you can set one of the following env variable:
 
   * SALUT_TEST_VALGRIND : to run Salut inside valgrind. The report is
     added to tools/gabble-testing.log.
+        export SALUT_TEST_VALGRIND=1
 
   * SALUT_TEST_REFDBG : to run Salut inside refdbg. The report is written
-    to tools/refdbg.log. You also need to setup SALUT_WRAPPER to your refdbg
-    command. Example:
-        export SALUT_WRAPPER="~/bin/refdbg -c btnum=16"
+    to tools/refdbg.log. You can change SALUT_WRAPPER to use an alternative
+    refdbg and change REFDBG_OPTIONS to set your own parameters. Example:
+        export SALUT_TEST_REFDBG=1
+        export SALUT_WRAPPER="/path/to/refdbg"
+        export REFDBG_OPTIONS="btnum=16"
 
   * SALUT_WRAPPER="nemiver" : to run Salut inside the graphical debugger
     nemiver. You'll be able to set up breakpoints; then hit the "continue"
diff --git a/tests/twisted/tools/exec-with-log.sh.in b/tests/twisted/tools/exec-with-log.sh.in
index 9de3850..bbd71a3 100644
--- a/tests/twisted/tools/exec-with-log.sh.in
+++ b/tests/twisted/tools/exec-with-log.sh.in
@@ -10,6 +10,13 @@ if test -n "$SALUT_TEST_VALGRIND"; then
 	export G_DEBUG=gc-friendly
 	export G_SLICE=always-malloc
 	SALUT_WRAPPER="valgrind --leak-check=full --num-callers=20"
+elif test -n "$SALUT_TEST_REFDBG"; then
+        if test -z "$REFDBG_OPTIONS" ; then
+                export REFDBG_OPTIONS="btnum=10"
+        fi
+        if test -z "$SALUT_WRAPPER" ; then
+                SALUT_WRAPPER="refdbg"
+        fi
 fi
 
 exec $SALUT_WRAPPER @abs_top_builddir@/src/telepathy-salut
-- 
1.5.6.5



More information about the Telepathy-commits mailing list