mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-12-18 11:00:25 +00:00
Use Error instead of Errorf
If the string formatting is not required use Error. Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
parent
b1dfcb4d7e
commit
84aa1ba392
@ -157,7 +157,7 @@ func TestConnPool(t *testing.T) {
|
||||
// force expiring the ConnEntry by fetching it and adjusting .lastUsed
|
||||
ce, exists := cp.conns[unique]
|
||||
if !exists {
|
||||
t.Errorf("getting the conn from cp.conns failed")
|
||||
t.Error("getting the conn from cp.conns failed")
|
||||
}
|
||||
ce.lastUsed = ce.lastUsed.Add(-2 * expiry)
|
||||
|
||||
|
@ -29,13 +29,13 @@ func TestGetPIDLimix(t *testing.T) {
|
||||
t.Errorf("no error should be returned, got: %v", err)
|
||||
}
|
||||
if limit == 0 {
|
||||
t.Errorf("a PID limit of 0 is invalid")
|
||||
t.Error("a PID limit of 0 is invalid")
|
||||
}
|
||||
|
||||
// this is expected to fail when not run as root
|
||||
err = SetPIDLimit(4096)
|
||||
if err != nil {
|
||||
t.Logf("failed to set PID limit, are you running as root?")
|
||||
t.Log("failed to set PID limit, are you running as root?")
|
||||
} else {
|
||||
// in case it worked, reset to the previous value
|
||||
err = SetPIDLimit(limit)
|
||||
|
Loading…
Reference in New Issue
Block a user