fix: Update min/max zoom value and fit view values (#7113)
* fix: Update minZoom value in PageComponent to improve zoom functionality * [autofix.ci] apply automated fixes * fix: Add fitViewOptions to PageComponent for enhanced zoom control * fix: update default zoom out level in adjustScreenView utility Changed the default value of numberOfZoomOut from 3 to 1 in the adjustScreenView function to improve initial screen adjustment behavior. * fix: update zoom out level in filterEdge test Modified the filterEdge test to pass a specific zoom out level of 3 to the adjustScreenView function, ensuring consistent screen adjustments during test execution. * chore: update .gitignore to exclude .qodo files * fix tests * fixed test * fix loop on zoom out * Remove unnecessary zoom out click in starter projects test to improve test accuracy. --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Mike Fortman <michael.fortman@datastax.com> Co-authored-by: Lucas Oliveira <62335616+lucaseduoli@users.noreply.github.com> Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
This commit is contained in:
parent
6a9a4e94ff
commit
f99469f06d
12 changed files with 44 additions and 37 deletions
|
|
@ -3,7 +3,7 @@ import { Page } from "playwright/test";
|
|||
export async function adjustScreenView(
|
||||
page: Page,
|
||||
{
|
||||
numberOfZoomOut = 3,
|
||||
numberOfZoomOut = 1,
|
||||
}: {
|
||||
numberOfZoomOut?: number;
|
||||
} = {},
|
||||
|
|
@ -11,6 +11,12 @@ export async function adjustScreenView(
|
|||
await page.getByTestId("fit_view").click();
|
||||
|
||||
for (let i = 0; i < numberOfZoomOut; i++) {
|
||||
await page.getByTestId("zoom_out").click();
|
||||
const zoomOutButton = page.getByTestId("zoom_out");
|
||||
|
||||
if (await zoomOutButton.isDisabled()) {
|
||||
break;
|
||||
} else {
|
||||
await zoomOutButton.click();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { Page } from "@playwright/test";
|
||||
|
||||
export async function zoomOut(page: Page, times: number = 4) {
|
||||
export async function zoomOut(page: Page, times: number = 2) {
|
||||
for (let i = 0; i < times; i++) {
|
||||
await page.getByTestId("zoom_out").click();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue