mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
chore(ct): svelte mount options type dedupe (#16868)
This commit is contained in:
parent
a10bd6a7c6
commit
3464edf89d
21
packages/playwright-ct-svelte/index.d.ts
vendored
21
packages/playwright-ct-svelte/index.d.ts
vendored
@ -34,23 +34,20 @@ export type PlaywrightTestConfig = Omit<BasePlaywrightTestConfig, 'use'> & {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export interface MountOptions<Props = Record<string, unknown>> {
|
||||||
|
props?: Props,
|
||||||
|
slots?: Record<string, unknown>,
|
||||||
|
on?: Record<string, Function>,
|
||||||
|
hooksConfig?: any,
|
||||||
|
}
|
||||||
|
|
||||||
interface MountResult extends Locator {
|
interface MountResult extends Locator {
|
||||||
unmount(): Promise<void>;
|
unmount(): Promise<void>;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ComponentFixtures {
|
interface ComponentFixtures {
|
||||||
mount(component: any, options?: {
|
mount(component: any, options?: MountOptions): Promise<MountResult>;
|
||||||
props?: { [key: string]: any },
|
mount<Props>(component: any, options: MountOptions<Required<Props>>): Promise<MountResult>;
|
||||||
slots?: { [key: string]: any },
|
|
||||||
on?: { [key: string]: Function },
|
|
||||||
hooksConfig?: any,
|
|
||||||
}): Promise<MountResult>;
|
|
||||||
mount<Props>(component: any, options: {
|
|
||||||
props: Props,
|
|
||||||
slots?: { [key: string]: any },
|
|
||||||
on?: { [key: string]: Function },
|
|
||||||
hooksConfig?: any,
|
|
||||||
}): Promise<MountResult>;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export const test: TestType<
|
export const test: TestType<
|
||||||
|
Loading…
x
Reference in New Issue
Block a user