ERROR[0000] could not initialize test

Hello , I am also facing the same issue while running the script

ERRO[0000] could not initialize ‘Documents/k6_perf_POC/frontendScripts/fillform.js’: could not load JS test ‘file:///Users/tripate/Documents/k6_perf_POC/frontendScripts/fillform.js’: file:///Users/tripate/Documents/k6_perf_POC/frontendScripts/fillform.js: Line 19:25 Unexpected token function (and 6 more errors)

Hi @ElimaTripathy ,

Your script contains references to Async / Await JS API, probably because you copied it directly from xk6-browser Github repo, but this feature is currently in development and about to be released in v0.8.0.

So if you are using v0.7.0 of xk6-browser, which is the latest released, you should use this version of the script. You an also build xk6-browse from source to get the current version in development following this instructions. Or wait for the v0.8.0 release which should come out soon this week.

Let me know if that solves the issue.

1 Like