Commit d8187fce authored by Han-Wen Nienhuys's avatar Han-Wen Nienhuys

posixtest: provide more detail for failing ReadDir test

Change-Id: I2b996ca3bfd1ea7e605e4dfd785cba2796340cd5
parent f57e95bd
......@@ -487,11 +487,16 @@ func ReadDir(t *testing.T, mnt string) {
got[e] = true
}
if len(got) != len(want) {
t.Errorf("got %d entries, want %d", len(got), len(want))
t.Errorf("mismatch got %d want %d", len(got), len(want))
}
for k := range got {
if !want[k] {
t.Errorf("got unknown name %q", k)
t.Errorf("got extra entry %q", k)
}
}
for k := range want {
if !got[k] {
t.Errorf("missing entry %q", k)
}
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment