We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b436462 commit e2e7e9cCopy full SHA for e2e7e9c
scanpipe/tests/test_api.py
@@ -665,6 +665,9 @@ def test_scanpipe_api_project_action_results_download_output_formats(self):
665
"application/octet-stream",
666
]
667
self.assertIn(response["Content-Type"], expected)
668
+ # Forces Django to finish the response and close the file
669
+ # to prevent a "ResourceWarning: unclosed file"
670
+ self.assertTrue(response.getvalue().startswith(b"PK"))
671
672
def test_scanpipe_api_project_action_pipelines(self):
673
url = reverse("project-pipelines")
0 commit comments