Skip to content

Commit 33f49b5

Browse files
test: Fix test_should_call_notifications_with_pending_uploads_in_db
Update test to explicitly set report_type=COVERAGE for uploads since the fix now filters remaining_uploads by report_type. Without this, the uploads wouldn't be counted and the test would fail.
1 parent 0a2a75d commit 33f49b5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

apps/worker/tasks/tests/unit/test_upload_finisher_task.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -564,14 +564,17 @@ def test_should_call_notifications_with_pending_uploads_in_db(
564564
repository__author__username="ThiagoCodecov",
565565
repository__yaml=commit_yaml,
566566
)
567-
# Create uploads in UPLOADED state (still being processed)
567+
# Create coverage uploads in UPLOADED state (still being processed)
568+
# These should block notifications since they're coverage uploads
568569
upload1 = UploadFactory.create(
569570
report__commit=commit,
571+
report__report_type=ReportType.COVERAGE.value,
570572
state="started",
571573
state_id=UploadState.UPLOADED.db_id,
572574
)
573575
upload2 = UploadFactory.create(
574576
report__commit=commit,
577+
report__report_type=ReportType.COVERAGE.value,
575578
state="started",
576579
state_id=UploadState.UPLOADED.db_id,
577580
)

0 commit comments

Comments
 (0)