mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
Merge pull request #2738 from kolyshkin/unit-verbose
ci/unit tests: decrease verbosity
This commit is contained in:
@@ -26,7 +26,6 @@ func testDeviceFilter(t testing.TB, devices []*devices.Rule, expectedStr string)
|
||||
t.Fatalf("%s: %v (devices: %+v)", t.Name(), err, devices)
|
||||
}
|
||||
s := insts.String()
|
||||
t.Logf("%s: devices: %+v\n%s", t.Name(), devices, s)
|
||||
if expectedStr != "" {
|
||||
hashed := hash(s, "//")
|
||||
expectedHashed := hash(expectedStr, "//")
|
||||
|
||||
@@ -40,19 +40,16 @@ func TestRangeToBits(t *testing.T) {
|
||||
}
|
||||
|
||||
for _, tc := range testCases {
|
||||
t.Logf("case: %q", tc.in)
|
||||
out, err := rangeToBits(tc.in)
|
||||
if err != nil {
|
||||
t.Logf(" got error: %s", err)
|
||||
if !tc.isErr {
|
||||
t.Error(" ^^^ unexpected error")
|
||||
t.Errorf("case %q: unexpected error: %v", tc.in, err)
|
||||
}
|
||||
|
||||
continue
|
||||
}
|
||||
t.Logf(" expected %v, got %v", tc.out, out)
|
||||
if !bytes.Equal(out, tc.out) {
|
||||
t.Error(" ^^^ unexpected result")
|
||||
t.Errorf("case %q: expected %v, got %v", tc.in, tc.out, out)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -501,9 +501,8 @@ func TestGetHugePageSizeImpl(t *testing.T) {
|
||||
warns.Reset()
|
||||
output, err := getHugePageSizeFromFilenames(c.input)
|
||||
if err != nil {
|
||||
t.Logf("(input %v, error %v)", c.input, err)
|
||||
if !c.isErr {
|
||||
t.Error("unexpected error ^^^^")
|
||||
t.Errorf("input %v, expected nil, got error: %v", c.input, err)
|
||||
}
|
||||
// no more checks
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user