upthewaterspout commented on a change in pull request #6461:
URL: https://github.com/apache/geode/pull/6461#discussion_r631952888
##########
File path:
geode-apis-compatible-with-redis/src/integrationTest/java/org/apache/geode/redis/internal/executor/hash/HScanIntegrationTest.java
##########
@@ -64,27 +59,4 @@ public void
givenCursorLessThanIntMinValue_returnsCursorError() {
assertThatThrownBy(() -> jedis.hscan("a", tooSmallCursor.toString()))
.hasMessageContaining(ERROR_CURSOR);
}
-
-
- @Test
- public void givenCount_shouldReturnExpectedNumberOfEntries() {
- Map<byte[], byte[]> entryMap = new HashMap<>();
- entryMap.put("1".getBytes(), "yellow".getBytes());
- entryMap.put("2".getBytes(), "green".getBytes());
- entryMap.put("3".getBytes(), "orange".getBytes());
- jedis.hmset("colors".getBytes(), entryMap);
-
- int COUNT_PARAM = 2;
-
- ScanParams scanParams = new ScanParams();
- scanParams.count(COUNT_PARAM);
- ScanResult<Map.Entry<byte[], byte[]>> result;
-
- String cursor = "0";
-
- result = jedis.hscan("colors".getBytes(), cursor.getBytes(), scanParams);
-
- assertThat(result.getResult().size()).isEqualTo(COUNT_PARAM);
- }
-
Review comment:
hscan is allowed to return more than `count` number of entries, due to
hash collisions. This test would now fail with both native redis and radish.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]