Skip to content

Commit

Permalink
Extend test coverage of dashboard app components.file
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhwaniartefact authored Apr 29, 2024
1 parent 37ba46a commit 2dd5a23
Show file tree
Hide file tree
Showing 4 changed files with 480 additions and 3 deletions.
8 changes: 7 additions & 1 deletion src/dashboard/src/components/file/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,19 @@

app_name = "file"
urlpatterns = [
re_path(r"(?P<fileuuid>" + settings.UUID_REGEX + ")/$", views.file_details),
re_path(
r"(?P<fileuuid>" + settings.UUID_REGEX + ")/$",
views.file_details,
name="file_details",
),
re_path(
r"(?P<fileuuid>" + settings.UUID_REGEX + ")/tags/$",
views.TransferFileTags.as_view(),
name="transfer_file_tags",
),
re_path(
r"(?P<fileuuid>" + settings.UUID_REGEX + ")/bulk_extractor/$",
views.bulk_extractor,
name="bulk_extractor",
),
]
3 changes: 1 addition & 2 deletions src/dashboard/src/components/file/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,7 @@ def bulk_extractor(request, fileuuid):
+ fileuuid
)
logger.error(message + "; response: %s", (response.text,))
response = {"success": False, "message": message}
helpers.json_response(response, status_code=500)
continue

features[report] = _parse_bulk_extractor_report(response.text)

Expand Down
Empty file.
Loading

0 comments on commit 2dd5a23

Please sign in to comment.