]> git.llucax.com Git - software/mutest.git/commitdiff
Make test cases execute in alphabetic order
authorLeandro Lucarella <llucarella@integratech.com.ar>
Mon, 15 Dec 2008 19:40:16 +0000 (17:40 -0200)
committerLeandro Lucarella <llucarella@integratech.com.ar>
Mon, 15 Dec 2008 19:40:16 +0000 (17:40 -0200)
Remove nm's -p switch so alphabetic order is used to get the test suite
symbols (test cases and initialization/termination functions). This way
execution order can be deterministic.

mkmutest
mutest

index 32c0e5adbeaddc8b94c56d8f3deb4c5d30088f73..763cc927dc04ce81b6196f12f97ea4794575fe09 100755 (executable)
--- a/mkmutest
+++ b/mkmutest
@@ -34,7 +34,7 @@ for file in "$@"
 do
        pr_file=`echo "$file" | sed 's/\"/\\\\\"/g'`
        suite=`basename "$file" .o | sed 's/\"/\\\\\"/g'`
-       symbols=`nm -p "$file" | egrep '^[[:xdigit:]]{8} T mu_\w+$' | cut -c12-`
+       symbols=`nm "$file" | egrep '^[[:xdigit:]]{8} T mu_\w+$' | cut -c12-`
        tests=`echo "$symbols" | egrep '^mu_test'`
        inits=`echo "$symbols" | egrep '^mu_init'`
        terms=`echo "$symbols" | egrep '^mu_term'`
diff --git a/mutest b/mutest
index 44d6414fa1f0b082996b037981636d18f0255a34..a0e7d82eb66b8728493732d8ac75c1285c8059b8 100755 (executable)
--- a/mutest
+++ b/mutest
@@ -102,7 +102,7 @@ class TestSuiteInfo (object):
        cases_re = re.compile(r'[0-9a-f]{8} T (mu_test\w*)', re.I)
 
        def __init__(self, so_name):
-               proc = Popen(['nm', '-p', so_name], stdout=PIPE)
+               proc = Popen(['nm', so_name], stdout=PIPE)
                output = proc.communicate()[0]
                self.inits = self.inits_re.findall(output)
                self.terms = self.terms_re.findall(output)