Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/__tests__/pokemon-list.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ describe("Pokemon list with 'Load more' button", () => {
// Check that the summary correctly says how many items are shown
expect(
await screen.findByText(
`Displaying 5 of ${pokemonsResultPage1.count} results`
new RegExp(`Displaying 5 of ${pokemonsResultPage1.count} results`, 's')
)
).toBeInTheDocument();
});
Expand All @@ -89,7 +89,7 @@ describe("Pokemon list with 'Load more' button", () => {
// Check that the summary correctly updated
expect(
await screen.findByText(
`Displaying 10 of ${pokemonsResultPage1.count} results`
new RegExp(`Displaying 10 of ${pokemonsResultPage1.count} results`, 's')
)
).toBeInTheDocument();

Expand Down Expand Up @@ -125,7 +125,7 @@ describe("Pokemon list with 'Load more' button", () => {

// Check that the summary correctly updated
expect(
await screen.findByText("Displaying 12 of 12 results")
await screen.findByText(/Displaying 12 of 12 results/)
).toBeInTheDocument();

// Check that 12 items are displayed
Expand Down