feat: add audit logging for admin trash restore/purge and notification clear actions
- Record audit events in `admin_trash_restore` and `admin_trash_purge` endpoints with target metadata - Log `notification.read.all` event when user clears devRant notification feed - Include `devrant` as a valid origin in audit categories - Add `admin_section` and `pagination_query` fields to audit and backup schemas for UI consistency
This commit is contained in:
@@ -35,3 +35,16 @@ def test_db_mutation_tools_record_and_confirm():
|
||||
assert action.is_read_only is False
|
||||
assert _records_mutation(name) is True
|
||||
assert name in CONFIRM_REQUIRED
|
||||
|
||||
|
||||
def test_seo_report_is_public_read_only_http_action():
|
||||
action = BY_NAME["seo_report"]
|
||||
assert action.handler == "http"
|
||||
assert action.method == "GET"
|
||||
assert action.path == "/tools/seo/{uid}/report"
|
||||
assert action.requires_auth is False
|
||||
assert action.is_read_only is True
|
||||
assert _records_mutation("seo_report") is False
|
||||
assert "seo_report" not in CONFIRM_REQUIRED
|
||||
names = {p.name for p in action.params}
|
||||
assert "uid" in names
|
||||
|
||||
Reference in New Issue
Block a user