Skip to content

Commit

Permalink
test that indexpattern service has not been called
Browse files Browse the repository at this point in the history
  • Loading branch information
stratoula committed Feb 19, 2021
1 parent e2f39a5 commit 2d4f030
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -377,8 +377,9 @@ describe('loader', () => {

it('should load a default state without loading the indexPatterns when embedded', async () => {
const storage = createMockStorage();
const indexPatternsService = mockIndexPatternsService();
const state = await loadInitialState({
indexPatternsService: mockIndexPatternsService(),
indexPatternsService,
storage,
options: { isFullEditor: false },
});
Expand All @@ -391,6 +392,7 @@ describe('loader', () => {
});

expect(storage.set).not.toHaveBeenCalled();
expect(indexPatternsService.getIdsWithTitle).not.toHaveBeenCalled();
});

it('should load a default state when lastUsedIndexPatternId is not found in indexPatternRefs', async () => {
Expand Down

0 comments on commit 2d4f030

Please sign in to comment.