0

I have a project web.testing.dependent, which refers to the page object models from web.testing.referenced project.

web.testing.referenced project has been packaged and published to the local registry and it is then added as a dependency to web.testing.dependent project.

It is possible to import and access the elements of page object model in nightwatch tests, but it fails with the following error when the test is executed.

enter image description here

Below are the configuration details of the referenced project:

Nightwatch version: 3.3

tsconfig.json:

enter image description here

Appreciate any guidance on resolving this problem.

nightwatch.conf.js

enter image description here

In my case, in the dependent project I already have some page objects and want to refer page objects from reference projects which contains page objects which will be re-used by multiple different projects. Alternatively, I also tried to use simple native JS classes (as drivers), which simply encapsulates driver functions

2
  • What is in the page objects section of your nightwatch.conf.js? Commented Nov 28, 2023 at 12:19
  • please see updated section @AutomatedTester Commented Nov 29, 2023 at 13:13

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.