File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -96,7 +96,7 @@ export async function initializeExtension(
96
96
state : PlaywrightState ,
97
97
) : Promise < Response . Keywords > {
98
98
logger . info ( `Initializing extension: ${ request . getPath ( ) } ` ) ;
99
- const extension : Record < string , ( ...args : unknown [ ] ) => unknown > = eval ( ' require' ) ( request . getPath ( ) ) ;
99
+ const extension : Record < string , ( ...args : unknown [ ] ) => unknown > = require ( request . getPath ( ) ) ; // eslint-disable-line
100
100
state . extensions . push ( extension ) ;
101
101
const kws = Object . keys ( extension ) . filter ( ( key ) => extension [ key ] instanceof Function && ! key . startsWith ( '__' ) ) ;
102
102
logger . info ( `Adding ${ kws . length } keywords from JS Extension` ) ;
@@ -1140,7 +1140,7 @@ async function _saveCoverageReport(activeIndexedPage: IndexedPage): Promise<Resp
1140
1140
let mergedOptions : CoverageReportOptions ;
1141
1141
if ( fs . existsSync ( configFile ) ) {
1142
1142
logger . info ( { 'Config file exists: ' : configFile } ) ;
1143
- const configFileModule = await eval ( ' require' ) ( configFile ) ;
1143
+ const configFileModule = require ( configFile ) ; // eslint-disable-line
1144
1144
mergedOptions = { ...configFileModule , ...options } ;
1145
1145
console . log ( { 'Merged options: ' : mergedOptions } ) ;
1146
1146
} else {
You can’t perform that action at this time.
0 commit comments