Skip to content

Commit 8624a02

Browse files
committed
t
1 parent 75cde70 commit 8624a02

2 files changed

Lines changed: 7 additions & 8 deletions

File tree

cypress/cypress/component/Paging/Paging.cy.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import { mount } from "cypress/react";
44

55
describe("Paging.cy.tsx", () => {
66
it("basic paging works", () => {
7-
const itemsPerPage = faker.datatype.number({ min: 1, max: 999 });
8-
const pages = faker.datatype.number({ min: 3, max: 999 });
9-
const currentPage = faker.datatype.number({ min: 2, max: pages - 1 });
7+
const itemsPerPage = faker.number.int({ min: 1, max: 999 });
8+
const pages = faker.number.int({ min: 3, max: 999 });
9+
const currentPage = faker.number.int({ min: 2, max: pages - 1 });
1010
const translations = { showedItemsText: "Item {from} to {to} from {total}", itemsPerPageDropdown: "Items per page" };
1111

1212
mount(
@@ -32,7 +32,7 @@ describe("Paging.cy.tsx", () => {
3232
cy.get("[data-cy-root] > .container-fluid > .row > .col-6:first-of-type > .btn-group > .dropdown-menu > .dropdown-item").then(
3333
(items: JQuery<HTMLElement>) => {
3434
expect(items.map((_, item) => item.textContent).toArray(), "possible items per page").to.deep.eq(
35-
[25, 50, 100, 200, itemsPerPage].sort((a, b) => a - b).map((itemNumber): string => itemNumber.toString()),
35+
[25, 50, 100, 200, itemsPerPage].toSorted((a, b) => a - b).map((itemNumber): string => itemNumber.toString()),
3636
);
3737
cy.wrap(items.filter((_, item) => item.textContent === "25")).click();
3838
cy.get("@setItemsPerPage").should("be.calledOnceWith", 25);
@@ -70,9 +70,9 @@ describe("Paging.cy.tsx", () => {
7070
});
7171

7272
it("paging without change of page size", () => {
73-
const itemsPerPage = faker.datatype.number({ min: 1, max: 999 });
74-
const pages = faker.datatype.number({ min: 3, max: 999 });
75-
const currentPage = faker.datatype.number({ min: 2, max: pages - 1 });
73+
const itemsPerPage = faker.number.int({ min: 1, max: 999 });
74+
const pages = faker.number.int({ min: 3, max: 999 });
75+
const currentPage = faker.number.int({ min: 2, max: pages - 1 });
7676
const translations = { showedItemsText: "Item {from} to {to} from {total}", itemsPerPageDropdown: "Items per page" };
7777

7878
mount(

cypress/cypress/component/PanelSidebar/PanelSidebar.cy.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* eslint-disable max-lines */
21
import { PropsWithChildren } from "react";
32
import {
43
PanelSideBarProvider,

0 commit comments

Comments
 (0)