diff options
author | Jeremy Davis <jeremy.davis@sonarsource.com> | 2022-01-19 19:38:36 +0100 |
---|---|---|
committer | sonartech <sonartech@sonarsource.com> | 2022-01-21 20:03:21 +0000 |
commit | 1ebc69c4f13a3f4e02fb742ded5ec529094709ce (patch) | |
tree | ea258273c4962eb2998d6180728934c32fd23fbf /server | |
parent | af0d50a5635d898174484c5072bbcf24c468df69 (diff) | |
download | sonarqube-1ebc69c4f13a3f4e02fb742ded5ec529094709ce.tar.gz sonarqube-1ebc69c4f13a3f4e02fb742ded5ec529094709ce.zip |
[NO-JIRA] Fix unit tests
Diffstat (limited to 'server')
4 files changed, 4 insertions, 4 deletions
diff --git a/server/sonar-web/src/main/js/app/components/indexation/__tests__/IndexationNotificationHelper-test.tsx b/server/sonar-web/src/main/js/app/components/indexation/__tests__/IndexationNotificationHelper-test.tsx index 82e53f3c821..b98ee43d3ed 100644 --- a/server/sonar-web/src/main/js/app/components/indexation/__tests__/IndexationNotificationHelper-test.tsx +++ b/server/sonar-web/src/main/js/app/components/indexation/__tests__/IndexationNotificationHelper-test.tsx @@ -28,7 +28,7 @@ beforeEach(() => { }); jest.mock('../../../../api/ce', () => ({ - getIndexationStatus: jest.fn() + getIndexationStatus: jest.fn().mockResolvedValue({}) })); jest.mock('../../../../helpers/storage', () => ({ diff --git a/server/sonar-web/src/main/js/apps/application-console/__tests__/CreateBranchForm-test.tsx b/server/sonar-web/src/main/js/apps/application-console/__tests__/CreateBranchForm-test.tsx index 383dfc1cbba..91c441bb628 100644 --- a/server/sonar-web/src/main/js/apps/application-console/__tests__/CreateBranchForm-test.tsx +++ b/server/sonar-web/src/main/js/apps/application-console/__tests__/CreateBranchForm-test.tsx @@ -26,7 +26,7 @@ import { Application } from '../../../types/application'; import CreateBranchForm from '../CreateBranchForm'; jest.mock('../../../api/application', () => ({ - getApplicationDetails: jest.fn().mockResolvedValue({}), + getApplicationDetails: jest.fn().mockResolvedValue({ projects: [] }), addApplicationBranch: jest.fn(), updateApplicationBranch: jest.fn() })); diff --git a/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/DirectoryFacet-test.tsx b/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/DirectoryFacet-test.tsx index c02ffe434bb..c3e722f65ab 100644 --- a/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/DirectoryFacet-test.tsx +++ b/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/DirectoryFacet-test.tsx @@ -28,7 +28,7 @@ import { Query } from '../../utils'; import DirectoryFacet from '../DirectoryFacet'; jest.mock('../../../../api/components', () => ({ - getDirectories: jest.fn().mockResolvedValue({}) + getDirectories: jest.fn().mockResolvedValue({ components: [] }) })); beforeEach(() => jest.clearAllMocks()); diff --git a/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/FileFacet-test.tsx b/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/FileFacet-test.tsx index 05f6cde0a30..dd55de47a1e 100644 --- a/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/FileFacet-test.tsx +++ b/server/sonar-web/src/main/js/apps/issues/sidebar/__tests__/FileFacet-test.tsx @@ -28,7 +28,7 @@ import { Query } from '../../utils'; import FileFacet from '../FileFacet'; jest.mock('../../../../api/components', () => ({ - getFiles: jest.fn().mockResolvedValue({}) + getFiles: jest.fn().mockResolvedValue({ components: [] }) })); beforeEach(() => jest.clearAllMocks()); |