From c41648a819eaee64b4f7c924cc68d4ca6555b4a7 Mon Sep 17 00:00:00 2001 From: Mathieu Suen Date: Fri, 26 Jan 2024 14:11:43 +0100 Subject: [PATCH] NO JIRA Improve frontend IT performance --- .../apps/background-tasks/__tests__/BackgroundTasks-it.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/server/sonar-web/src/main/js/apps/background-tasks/__tests__/BackgroundTasks-it.tsx b/server/sonar-web/src/main/js/apps/background-tasks/__tests__/BackgroundTasks-it.tsx index ca39fcc981f..8d849cd1f4b 100644 --- a/server/sonar-web/src/main/js/apps/background-tasks/__tests__/BackgroundTasks-it.tsx +++ b/server/sonar-web/src/main/js/apps/background-tasks/__tests__/BackgroundTasks-it.tsx @@ -36,6 +36,11 @@ import { TaskStatuses, TaskTypes } from '../../../types/tasks'; import { PAGE_SIZE } from '../constants'; import routes from '../routes'; +jest.mock('../constants', () => ({ + ...jest.requireActual('../constants'), + PAGE_SIZE: 9, +})); + const computeEngineServiceMock = new ComputeEngineServiceMock(); beforeAll(() => { @@ -185,7 +190,7 @@ describe('The Global background task page', () => { computeEngineServiceMock.clearTasks(); - const TOTAL_TASKS = 101; + const TOTAL_TASKS = 10; computeEngineServiceMock.createTasks(TOTAL_TASKS); -- 2.39.5