Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chapter 4 - Error: Playwright Test did not expect test.beforeAll() to be called here. #36

Open
SadhafAhmed opened this issue May 5, 2024 · 0 comments
Assignees
Labels
help wanted Extra attention is needed pending question Further information is requested

Comments

@SadhafAhmed
Copy link

Chapter 4 - when run test to see applitool example 3 spec seems to error...

Error: Playwright Test did not expect test.beforeAll() to be called here.
Most common reasons include:

  • You are calling test.beforeAll() in a configuration file.

  • You are calling test.beforeAll() in a file that is imported by the configuration file.

  • You have two different versions of @playwright/test. This usually happens
    when one of the dependencies in your package.json depends on @playwright/test.

    at tests\example3.spec.ts:26

    24 | export const USE_ULTRAFAST_GRID: boolean = false;
    25 | export let Batch: BatchInfo;

26 | export let Config: Configuration;
| ^
27 | export let Runner: EyesRunner;
28 | let eyes: Eyes;
29 | // end of Applitools
at TestTypeImpl._currentSuite (C:\PlaywrightCourse\tau-introduction-to-playwright\node_modules@playwright\test\lib\common\testType.js:69:13)
at TestTypeImpl._hook (C:\PlaywrightCourse\tau-introduction-to-playwright\node_modules@playwright\test\lib\common\testType.js:111:24)
at Function.beforeAll (C:\PlaywrightCourse\tau-introduction-to-playwright\node_modules@playwright\test\lib\common\transform.js:221:12)
at Object. (C:\PlaywrightCourse\tau-introduction-to-playwright\tests\example3.spec.ts:26:12)

Error: No tests found.
Make sure that arguments are regular expressions matching test files.
You may need to escape symbols like "$" or "*" and quote the arguments.

To open last HTML report run:

npx playwright show-report

Chapter4Error001

@SadhafAhmed SadhafAhmed added help wanted Extra attention is needed pending question Further information is requested labels May 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed pending question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants