@@ -193,43 +193,6 @@ describe('Account Manager Operations E2E Tests', function () {
193193 expect ( response ) . to . have . property ( 'id' ) . that . equals ( orgId ) ;
194194 expect ( response ) . to . have . property ( 'name' ) ;
195195 } ) ;
196-
197- it ( 'should get organization audit logs' , async function ( ) {
198- if ( ! hasOrgs ) {
199- console . log ( ' ⚠ No organizations available, skipping test' ) ;
200- this . skip ( ) ;
201- }
202-
203- const result = await runCLIWithRetry (
204- [ 'am' , 'orgs' , 'audit' , orgId , '--json' , '--auth-methods' , 'client-credentials' ] ,
205- {
206- timeout : TIMEOUTS . DEFAULT ,
207- verbose : true ,
208- env : AM_AUTH_ENV ,
209- } ,
210- ) ;
211-
212- // Skip if authentication/permission error (audit logs may require admin permissions)
213- if ( result . exitCode !== 0 ) {
214- const errorText = String ( result . stderr || result . stdout || '' ) ;
215- if (
216- errorText . includes ( 'Authentication invalid' ) ||
217- errorText . includes ( 'Access is denied' ) ||
218- errorText . includes ( '401' ) ||
219- errorText . includes ( '403' )
220- ) {
221- console . log ( ' ⚠ Insufficient permissions for audit logs, skipping test' ) ;
222- this . skip ( ) ;
223- }
224- }
225-
226- expect ( result . exitCode , `Org audit command failed: ${ result . stderr } ` ) . to . equal ( 0 ) ;
227-
228- const response = parseJSONOutput ( result ) ;
229- // Org audit --json returns an AuditLogCollection with content array
230- expect ( response ) . to . have . property ( 'content' ) ;
231- expect ( response . content ) . to . be . an ( 'array' ) ;
232- } ) ;
233196 } ) ;
234197
235198 describe ( 'Step 2: Users' , ( ) => {
0 commit comments