Spaces:
Sleeping
Sleeping
fix: correct all async route status code assertions (POST=202, GET poll=200)
Browse files
tests/integration/test_analyze_integration.py
CHANGED
|
@@ -250,7 +250,7 @@ def test_async_job_submission_returns_job_id(mock_pipeline, fake_repo):
|
|
| 250 |
json={"github_url": VALID_URL},
|
| 251 |
)
|
| 252 |
|
| 253 |
-
assert response.status_code ==
|
| 254 |
data = response.json()
|
| 255 |
assert "job_id" in data
|
| 256 |
assert isinstance(data["job_id"], str)
|
|
@@ -374,7 +374,7 @@ def test_async_job_full_poll_cycle_with_eager_execution(mock_pipeline, fake_repo
|
|
| 374 |
json={"github_url": VALID_URL},
|
| 375 |
)
|
| 376 |
|
| 377 |
-
assert submit_resp.status_code ==
|
| 378 |
job_id = submit_resp.json().get("job_id")
|
| 379 |
assert job_id, "Expected a job_id in the async submit response"
|
| 380 |
|
|
|
|
| 250 |
json={"github_url": VALID_URL},
|
| 251 |
)
|
| 252 |
|
| 253 |
+
assert response.status_code == 202
|
| 254 |
data = response.json()
|
| 255 |
assert "job_id" in data
|
| 256 |
assert isinstance(data["job_id"], str)
|
|
|
|
| 374 |
json={"github_url": VALID_URL},
|
| 375 |
)
|
| 376 |
|
| 377 |
+
assert submit_resp.status_code == 202
|
| 378 |
job_id = submit_resp.json().get("job_id")
|
| 379 |
assert job_id, "Expected a job_id in the async submit response"
|
| 380 |
|