@@ -64,14 +64,15 @@ public void shouldReturnUnknownCommandForUnknownCommandString() {
64
64
assertThat (RedisCommand .failsafeCommandLookup ("strangecommand" ), is (RedisCommand .UNKNOWN ));
65
65
}
66
66
67
- @ Test // DATAREDIS-73, DATAREDIS-972
67
+ @ Test // DATAREDIS-73, DATAREDIS-972, DATAREDIS-1013
68
68
public void shouldNotThrowExceptionOnValidArgumentCount () {
69
69
70
70
RedisCommand .AUTH .validateArgumentCount (1 );
71
71
RedisCommand .ZADD .validateArgumentCount (3 );
72
72
RedisCommand .ZADD .validateArgumentCount (4 );
73
73
RedisCommand .ZADD .validateArgumentCount (5 );
74
74
RedisCommand .ZADD .validateArgumentCount (100 );
75
+ RedisCommand .SELECT .validateArgumentCount (1 );
75
76
}
76
77
77
78
@ Test // DATAREDIS-822
@@ -86,16 +87,16 @@ public void shouldConsiderMinMaxArguments() {
86
87
public void shouldReportArgumentMismatchIfMaxArgumentsExceeded () {
87
88
88
89
expectedException .expect (IllegalArgumentException .class );
89
- expectedException .expectMessage ("BITPOS command requires at most 4 arguments " );
90
+ expectedException .expectMessage ("SELECT command requires 1 argument " );
90
91
91
- RedisCommand .BITPOS .validateArgumentCount (5 );
92
+ RedisCommand .SELECT .validateArgumentCount (0 );
92
93
}
93
94
94
95
@ Test // DATAREDIS-73
95
96
public void shouldThrowExceptionOnInvalidArgumentCountWhenExpectedExactMatch () {
96
97
97
98
expectedException .expect (IllegalArgumentException .class );
98
- expectedException .expectMessage ("AUTH command requires 1 arguments " );
99
+ expectedException .expectMessage ("AUTH command requires 1 argument " );
99
100
100
101
RedisCommand .AUTH .validateArgumentCount (2 );
101
102
}
@@ -104,7 +105,7 @@ public void shouldThrowExceptionOnInvalidArgumentCountWhenExpectedExactMatch() {
104
105
public void shouldThrowExceptionOnInvalidArgumentCountForDelWhenExpectedMinimalMatch () {
105
106
106
107
expectedException .expect (IllegalArgumentException .class );
107
- expectedException .expectMessage ("DEL command requires at least 1 arguments " );
108
+ expectedException .expectMessage ("DEL command requires at least 1 argument " );
108
109
109
110
RedisCommand .DEL .validateArgumentCount (0 );
110
111
}
0 commit comments