Closed octadecimal closed 1 year ago
Thanks for reporting!
The test project was very helpful in reproducing the issue. After a short investigation, I think this is related to the yarn package manager in combination with the use of the child process exec cwd option. The cwd option is used to change the working directory to the apps/client-e2e
path. When I switch to npm/npx in your test project the configuration works. I need to do a bit more testing to see if I can change the cwd option and use the full configPath
path as you suggested.
:tada: This issue has been resolved in version 1.5.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
Thank you for the amazingly quick turn-around -- and for the plugin as well! I've updated to 1.5.1 and can confirm it's working as expected on my side now. :+1:
Current Behavior
Hi, thanks for the cool library and taking the initiative to develop it. Out-of-the-box Nx integration with wdio is something I've wished for.
client
apps/client
@nx/react
client-e2e
apps/client-e2e
@rbnx/webdriverio
When I run:
I get the error:
I see that the executed command is passing
wdio.generated.config.ts
as if it lived at the workspace root, however the file is generated in the project's root (apps/client-e2e/wdio.generated.config.ts
).If I change this line in
run-wdio.ts
, to useconfigPath
instead ofconfigFile
from:to:
...it fixes this issue.
However, then the
import
path pointing towdio.config
is incorrect. I can modifyfiles/wdio.generated.config.ts__tmpl__
to fix this.So while I can workaround it, I can't help but to think I must be doing something fundamentally wrong, as I'd imagine such an obvious issue like this likely wouldn't be present.
Would you be able to offer me some guidance here, so that I could execute tests out-of-the-box without having to make the modifications I list above? I've set up a test project to repro for your convenience.
Expected Behaviour
Able to execute tests without modifications/workarounds, as outlined above.
Steps to Reproduce
yarn
yarn nx e2e client-e2e
Nx Report
Failure Logs
Additional Information
No response