So I've implemented tests using playwright with Page object model. Using the command line and VS Code Extension everything runs just fine. But when I launch the UI, it says No Tests! I've set testDir and
Here is my project structure: I've used Playwright with Typescript
Page classes are being passed to tests as fixtures using test.extend Fixtures class also exports the test, so I can import and use them in test classes.
Please let me know if you need any new details. Thanks in advance!
This thread is trying to answer question "Why is Playwright Test UI not detecting tests when implemented using Page object model and how can this issue be resolved?"
I've seen this issue happen when there's an error somewhere in the code base that the playwright is loading. For me, it was importing something in one test file that Playwright didn't like which caused this issue. Similarly it was extremely hard to figure this out, I only saw it once I ran the test in vscode and the error was thrown.
Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email [email protected].