-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
feat(test runner): allow to pass arbitrary location to test.step #32504
Changes from 17 commits
95ab5f3
50aeb59
1d21af8
2d9a489
8eb9a21
6d59f7b
97d8297
25eb816
f891b86
1473584
d48ddee
905e5ff
eaaf52b
082154d
0745b36
199e29a
4c3dbac
80047bf
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4703,7 +4703,7 @@ export interface TestType<TestArgs extends KeyValue, WorkerArgs extends KeyValue | |
* @param body Step body. | ||
* @param options | ||
*/ | ||
step<T>(title: string, body: () => T | Promise<T>, options?: { box?: boolean }): Promise<T>; | ||
step<T>(title: string, body: () => T | Promise<T>, options?: { box?: boolean, location?: Location }): Promise<T>; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please note that I'd suggest moving the definition of Playwright's @dgozman - what's your view? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looking at it along with the issues you mentioned, I think it's right to change like you said. |
||
/** | ||
* `expect` function can be used to create test assertions. Read more about [test assertions](https://playwright.dev/docs/test-assertions). | ||
* | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -128,7 +128,7 @@ export interface TestType<TestArgs extends KeyValue, WorkerArgs extends KeyValue | |
afterAll(inner: (args: TestArgs & WorkerArgs, testInfo: TestInfo) => Promise<any> | any): void; | ||
afterAll(title: string, inner: (args: TestArgs & WorkerArgs, testInfo: TestInfo) => Promise<any> | any): void; | ||
use(fixtures: Fixtures<{}, {}, TestArgs, WorkerArgs>): void; | ||
step<T>(title: string, body: () => T | Promise<T>, options?: { box?: boolean }): Promise<T>; | ||
step<T>(title: string, body: () => T | Promise<T>, options?: { box?: boolean, location?: Location }): Promise<T>; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In addition to this, you have to update documentation at |
||
expect: Expect<{}>; | ||
extend<T extends KeyValue, W extends KeyValue = {}>(fixtures: Fixtures<T, W, TestArgs, WorkerArgs>): TestType<TestArgs & T, WorkerArgs & W>; | ||
info(): TestInfo; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dgozman Thanks for the quick response to my modified commit! I will immediately reflect this part of your answer :)