Question about forkProcess in /lib/launcher.ts

9 views
Skip to first unread message

Barret Pickett

unread,
Aug 7, 2019, 11:47:06 PM8/7/19
to Angular and AngularJS discussion
Hello, what is the purpose of this line? https://github.com/angular/protractor/blob/cc501f71bc1f995a83c1041e1aa489ea0f105679/lib/launcher.ts#L210 What is the purpose of forking only when totalTasks > 1? In my case, I would like to fork even when running only a single spec file. The output format of the logs is different whether forkProcess is true or not. I would like it have consistent output format regardless of tests or suites run.

Sander Elias

unread,
Aug 14, 2019, 4:41:31 AM8/14/19
to Angular and AngularJS discussion
Hi Barret,

This is an optimization. Creating a fork takes resources/time. It's a waste if you only have 1 task. Testing takes long enough as it is. That is the reason it's built like this.

Regards
Sander

Reply all
Reply to author
Forward
0 new messages