I'm currently working on setting up Playwright for testing, and I've run into an issue that I could use some assistance with. I've followed all the necessary steps to create a new folder and a new test file, but when I attempt to run the test using the following command: 'npx playwright test .\tests\example.spec.js' I encounter the error message "No test found." However, when I run the basic test using just 'npx playwright test' it works perfectly.
This thread is trying to answer question "Why does the error message 'No test found' appear when trying to run a specific test file in Playwright?"
https://playwright.dev/docs/test-configuration the testDir property
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].