QC check
This commit is contained in:
@@ -8,6 +8,7 @@ import requests.exceptions
|
||||
|
||||
from utils.csv_processor import CSVProcessor
|
||||
|
||||
|
||||
@pytest.mark.unit
|
||||
class TestCSVProcessor:
|
||||
def setup_method(self):
|
||||
@@ -80,7 +81,9 @@ class TestCSVProcessor:
|
||||
# Mock failed HTTP response - need to make raise_for_status() raise an exception
|
||||
mock_response = Mock()
|
||||
mock_response.status_code = 404
|
||||
mock_response.raise_for_status.side_effect = requests.exceptions.HTTPError("404 Not Found")
|
||||
mock_response.raise_for_status.side_effect = requests.exceptions.HTTPError(
|
||||
"404 Not Found"
|
||||
)
|
||||
mock_get.return_value = mock_response
|
||||
|
||||
with pytest.raises(requests.exceptions.HTTPError):
|
||||
|
||||
Reference in New Issue
Block a user