sshiv012 commented on code in PR #8960:
URL: https://github.com/apache/texera/pull/8960#discussion_r4477600244


##########
amber/src/test/python/core/util/customized_queue/test_linked_blocking_multi_queue.py:
##########
@@ -282,9 +282,10 @@ def 
test_priority_group_peek_perturbs_round_robin_state(self):
 
         assert group.next_idx == 0
         assert group.peek() == "s"
-        # Skipping the empty `first` queue advanced next_idx, so peek is not
-        # side-effect free on the group's round-robin cursor.
-        assert group.next_idx == 1
+        assert group.next_idx == 0
+
+        lbmq.put("first", "f")
+        assert lbmq.get() == "f"
 

Review Comment:
   Could we also cover a nonzero starting cursor that wraps past an empty or 
disabled queue, using the public lbmq.peek()? The current test reproduces the 
original bug, this would protect the wraparound path too



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to