File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change 1
1
'use strict' ;
2
2
3
+ const _ = require ( 'lodash' ) ;
3
4
const Utils = require ( '../lib/Utils' ) ;
4
5
const Config = require ( '../lib/Config' ) ;
5
6
const request = require ( '../lib/request' ) ;
@@ -330,12 +331,9 @@ describe('Security Check', () => {
330
331
const checkGroups = [ Group ] ;
331
332
const runner = new CheckRunner ( { checkGroups, enableCheckLog : true } ) ;
332
333
const report = await runner . run ( ) ;
333
- console . log ( JSON . stringify ( report ) ) ;
334
- expect ( report ) . toBeDefined ( ) ;
335
- expect ( report . report ) . toBeDefined ( ) ;
336
- expect ( report . report . groups ) . toBeDefined ( ) ;
337
- expect ( report . report . groups . length ) . toBe ( 1 ) ;
338
- const titles = report . report . groups . flatMap ( group => group . checks . map ( check => check . title ) ) ;
334
+ const titles = _ . flatMap ( report . report . groups , group =>
335
+ group . checks . map ( check => check . title )
336
+ ) ;
339
337
expect ( titles . length ) . toBe ( 2 ) ;
340
338
341
339
for ( const title of titles ) {
You can’t perform that action at this time.
0 commit comments