Update what is being audit logged (#11833)

No need to audit log workflow runs as it's already a form of audit log.
Add more audit log for other objects
Rename MessagingTelemetry to MessagingMonitoring
Merge Analytics and Audit in one (Audit)

---------

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
This commit is contained in:
Félix Malfait
2025-05-04 14:35:41 +02:00
committed by GitHub
parent b1994f3707
commit 49b7f5255f
101 changed files with 948 additions and 1032 deletions

View File

@ -0,0 +1,19 @@
import { TrackEventName } from 'src/engine/core-modules/audit/types/events.type';
export const AuditContextMock = (params?: {
track?:
| ((
event: TrackEventName,
properties: any,
) => Promise<{ success: boolean }>)
| jest.Mock<any, any>;
pageview?:
| ((name: string, properties: any) => Promise<{ success: boolean }>)
| jest.Mock<any, any>;
}) => {
return {
track: params?.track ?? jest.fn().mockResolvedValue({ success: true }),
pageview:
params?.pageview ?? jest.fn().mockResolvedValue({ success: true }),
};
};