fix(test-runner): move OverriddenExpectProperties outside the namespace (#7319)
This commit is contained in:
parent
1157f622f3
commit
9f3bccc200
19
types/testExpect.d.ts
vendored
19
types/testExpect.d.ts
vendored
|
|
@ -29,17 +29,18 @@ export declare type Expect = {
|
||||||
stringMatching(expected: string | RegExp): AsymmetricMatcher;
|
stringMatching(expected: string | RegExp): AsymmetricMatcher;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
type OverriddenExpectProperties =
|
||||||
|
'not' |
|
||||||
|
'resolves' |
|
||||||
|
'rejects' |
|
||||||
|
'toMatchInlineSnapshot' |
|
||||||
|
'toThrowErrorMatchingInlineSnapshot' |
|
||||||
|
'toMatchSnapshot' |
|
||||||
|
'toThrowErrorMatchingSnapshot';
|
||||||
|
|
||||||
declare global {
|
declare global {
|
||||||
export namespace PlaywrightTest {
|
export namespace PlaywrightTest {
|
||||||
type OverriddenProperties =
|
export interface Matchers<R> extends Omit<expect.Matchers<R>, OverriddenExpectProperties> {
|
||||||
'not' |
|
|
||||||
'resolves' |
|
|
||||||
'rejects' |
|
|
||||||
'toMatchInlineSnapshot' |
|
|
||||||
'toThrowErrorMatchingInlineSnapshot' |
|
|
||||||
'toMatchSnapshot' |
|
|
||||||
'toThrowErrorMatchingSnapshot';
|
|
||||||
export interface Matchers<R> extends Omit<expect.Matchers<R>, OverriddenProperties> {
|
|
||||||
/**
|
/**
|
||||||
* If you know how to test something, `.not` lets you test its opposite.
|
* If you know how to test something, `.not` lets you test its opposite.
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue