File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -11,13 +11,13 @@ export interface CreateWorkerFixtureArgs {
1111}
1212
1313export function createWorkerFixture (
14- args : CreateWorkerFixtureArgs ,
14+ args ? : CreateWorkerFixtureArgs ,
1515 /** @todo `onUnhandledRequest`? */
1616) : TestFixture < WorkerFixture , any > {
1717 return async ( { page } , use ) => {
1818 const worker = new WorkerFixture ( {
1919 page,
20- initialHandlers : args . initialHandlers ,
20+ initialHandlers : args ? .initialHandlers || [ ] ,
2121 } )
2222
2323 await worker . start ( )
@@ -30,7 +30,7 @@ export class WorkerFixture extends SetupApi<LifeCycleEventsMap> {
3030 #page: Page
3131
3232 constructor ( args : { page : Page ; initialHandlers : Array < RequestHandler > } ) {
33- super ( ...( args . initialHandlers || [ ] ) )
33+ super ( ...args . initialHandlers )
3434 this . #page = args . page
3535 }
3636
You can’t perform that action at this time.
0 commit comments