File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88 "log"
99 "os"
1010 "os/exec"
11+ "regexp"
1112 "strings"
1213 "sync"
1314 "testing"
@@ -77,7 +78,7 @@ mount -t virtiofs myfs /mnt
7778
7879mkdir -p /mnt/tmp
7980
80- /posixtest.test -posixdir=/mnt -test.run TestAll -test.v \
81+ /posixtest.test -posixdir=/mnt -test.run TestAll -test.skip TestAll/DirectIO -test. v \
8182 > /mnt/test_output.txt 2>&1
8283echo $? > /mnt/test_exit.txt
8384
@@ -138,10 +139,12 @@ reboot -n -f
138139 // Report individual sub-test failures into Go's testing framework.
139140 for _ , line := range strings .Split (output , "\n " ) {
140141 line = strings .TrimSpace (line )
141- if strings . HasPrefix ( line , " --- FAIL:" ) {
142- name := strings . Fields ( line )[ 2 ]
143- t . Errorf ( "posixtest sub-test failed: %s" , name )
142+ m := regexp . MustCompile ( ` --- FAIL: *([^ ]*)\s\([0-9.]*s\)` ). FindStringSubmatch ( line )
143+ if m == nil {
144+ continue
144145 }
146+ name := m [1 ]
147+ t .Errorf ("posixtest sub-test failed: %s" , name )
145148 }
146149 if exitCode != "0" && exitCode != "" {
147150 t .Errorf ("posixtest.test exited with code %s" , exitCode )
You can’t perform that action at this time.
0 commit comments