MCPcopy Create free account
hub / github.com/openai/openai-python / test_flush_sync

Method test_flush_sync

tests/test_send_queue.py:42–51  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

40 assert q
41
42 def test_flush_sync(self) -> None:
43 q = SendQueue()
44 q.enqueue("a")
45 q.enqueue("b")
46 q.enqueue("c")
47
48 sent: list[str] = []
49 q.flush_sync(sent.append)
50 assert sent == ["a", "b", "c"]
51 assert len(q) == 0
52
53 def test_flush_sync_requeues_on_failure(self) -> None:
54 q = SendQueue()

Callers

nothing calls this directly

Calls 3

enqueueMethod · 0.95
flush_syncMethod · 0.95
SendQueueClass · 0.90

Tested by

no test coverage detected