-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Export products as csv file test (#4521)
* test bulk delete on product list * update single product test * test title fix * moved assertions to the end of tests * better selector for grid text * exclude rows eval from loop * print navigation url * Export products as csv test * removed unused log
- Loading branch information
1 parent
c7f36a6
commit 876d89b
Showing
9 changed files
with
163 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"saleor-dashboard": minor | ||
--- | ||
|
||
Export products as csv test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
export const LOCATORS = { | ||
successBanner: '[data-test-type="success"]', | ||
errorBanner: '[data-test-type="error"]', | ||
infoBanner: '[data-test-type="info"]', | ||
dataGridTable: "[data-testid='data-grid-canvas']", | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import { Page } from "@playwright/test"; | ||
|
||
export class ExportProductsDialog { | ||
readonly page: Page; | ||
|
||
constructor( | ||
page: Page, | ||
readonly channelsAccordion = page.getByTestId("channel-expand-button"), | ||
readonly nextButton = page.getByTestId("next"), | ||
readonly submitButton = page.getByTestId("submit"), | ||
readonly exportSearchedProductsRadioButton = page.locator( | ||
"input[value='FILTER']", | ||
), | ||
) { | ||
this.page = page; | ||
} | ||
async clickChannelsAccordion() { | ||
await this.channelsAccordion.click(); | ||
} | ||
async clickNextButton() { | ||
await this.nextButton.click(); | ||
} | ||
async clickSubmitButton() { | ||
await this.submitButton.click(); | ||
} | ||
async clickExportSearchedProductsRadioButton() { | ||
await this.exportSearchedProductsRadioButton.click(); | ||
} | ||
async checkChannelCheckbox(channel = "PLN") { | ||
await this.page.locator(`[name="Channel-${channel}"]`).click(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters