chore: remove debug check (#659)
Remove debug check now we run the test server with debug enabled if
needed.
diff --git a/redis/reply_test.go b/redis/reply_test.go
index 59bdba7..5ff3b5f 100644
--- a/redis/reply_test.go
+++ b/redis/reply_test.go
@@ -19,7 +19,6 @@
"math"
"reflect"
"strconv"
- "strings"
"testing"
"time"
@@ -227,17 +226,6 @@
}
}
-// debugCheck skips t if err indicates that DEBUG is not allowed,
-// otherwise it fails if err is not nil.
-func debugCheck(t *testing.T, err error) {
- t.Helper()
-
- if err != nil && strings.Contains(err.Error(), "ERR DEBUG command not allowed") {
- t.Skip("DEBUG command not allowed")
- }
- require.NoError(t, err)
-}
-
func TestLatency(t *testing.T) {
c, err := dial()
require.NoError(t, err)
@@ -265,7 +253,7 @@
// Sleep for 1ms to register a slow event.
_, err = c.Do("DEBUG", "SLEEP", 0.001)
- debugCheck(t, err)
+ require.NoError(t, err)
result, err = c.Do("LATENCY", "LATEST")
require.NoError(t, err)
@@ -317,7 +305,7 @@
// Sleep for 1ms to register a slow event
_, err = c.Do("DEBUG", "SLEEP", 0.001)
- debugCheck(t, err)
+ require.NoError(t, err)
result, err = c.Do("LATENCY", "HISTORY", "command")
require.NoError(t, err)