diff options
Diffstat (limited to 'spec/frontend/diffs/components/app_spec.js')
-rw-r--r-- | spec/frontend/diffs/components/app_spec.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/spec/frontend/diffs/components/app_spec.js b/spec/frontend/diffs/components/app_spec.js index b69452069c0..fb5cf4dfd0a 100644 --- a/spec/frontend/diffs/components/app_spec.js +++ b/spec/frontend/diffs/components/app_spec.js @@ -73,6 +73,8 @@ describe('diffs/components/app', () => { propsData: { endpointCoverage: `${TEST_HOST}/diff/endpointCoverage`, endpointCodequality: '', + endpointSast: '', + projectPath: 'namespace/project', currentUser: {}, changesEmptyStateIllustration: '', ...props, @@ -184,6 +186,16 @@ describe('diffs/components/app', () => { }); }); + describe('SAST diff', () => { + it('does not fetch Sast data on FOSS', () => { + createComponent(); + jest.spyOn(wrapper.vm, 'fetchSast'); + wrapper.vm.fetchData(false); + + expect(wrapper.vm.fetchSast).not.toHaveBeenCalled(); + }); + }); + it('displays loading icon on loading', () => { createComponent({}, ({ state }) => { state.diffs.isLoading = true; |