Skip to content

Commit 29951b2

Browse files
fix: match test assertions against AirbyteTracedException message field
The pytest.raises(match=...) regex matches against the exception's string representation, which uses the 'message' field, not 'internal_message'. Updated the two is_done safety check tests to match against the correct message text. Co-Authored-By: alfredo.garcia@airbyte.io <freddy.garcia7.fg@gmail.com>
1 parent e1bd626 commit 29951b2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

unit_tests/sources/streams/concurrent/test_concurrent_read_processor.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1441,7 +1441,7 @@ def test_is_done_raises_when_partition_generation_queue_not_empty():
14411441
# Artificially mark the stream as done without removing it from the partition generation queue
14421442
handler._streams_done.add("stuck_stream")
14431443

1444-
with pytest.raises(AirbyteTracedException, match="remained in the partition generation queue"):
1444+
with pytest.raises(AirbyteTracedException, match="Partition generation queue is not empty"):
14451445
handler.is_done()
14461446

14471447

@@ -1480,7 +1480,7 @@ def test_is_done_raises_when_active_groups_not_empty():
14801480
handler._active_groups["my_group"] = {"stuck_stream"}
14811481

14821482
with pytest.raises(
1483-
AirbyteTracedException, match="still active after all streams were marked done"
1483+
AirbyteTracedException, match="Active stream groups are not empty"
14841484
):
14851485
handler.is_done()
14861486

0 commit comments

Comments
 (0)