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

fix(test runner): remove folio/jest namespaces in expect matchers #6930

Merged
merged 1 commit into from
Jun 7, 2021

Conversation

dgozman
Copy link
Contributor

@dgozman dgozman commented Jun 7, 2021

We'll be able to bring jest namespace back if/when needed.

@dgozman dgozman requested a review from mxschmitt June 7, 2021 03:36
interface Matchers<R> {
toBeWithinRange(a: number, b: number): R;
}
}
```

To import expect matching libraries like [jest-extended](https://github.com/jest-community/jest-extended#installation) you can import it from your `global.d.ts`:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't something like that work for users then? (move extending from jest from us to the use-space). Then the native expect-extend imports should work out of the box.

declare namespace PlaywrightTest {
  interface Matchers<R> extends jest.Matchers<R> {
  }
}

@dgozman dgozman merged commit 8c13f67 into microsoft:master Jun 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants