Skip to content

Commit

Permalink
[Discover] Fix typescript errors
Browse files Browse the repository at this point in the history
  • Loading branch information
jughosta committed Jan 17, 2024
1 parent a1643b4 commit 2033a6d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { dataViewWithTimefieldMock } from '../__mocks__/data_view_with_timefield
import { unifiedHistogramServicesMock } from '../__mocks__/services';
import { lensAdaptersMock } from '../__mocks__/lens_adapters';
import { ChartConfigPanel } from './chart_config_panel';
import type { LensAttributesContext } from './utils/get_lens_attributes';
import type { LensAttributesContext } from '../types';

describe('ChartConfigPanel', () => {
it('should return a jsx element to edit the visualization', async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ describe('useStateProps', () => {
totalHitsStatus: UnifiedHistogramFetchStatus.uninitialized,
totalHitsResult: undefined,
currentSuggestion: undefined,
externalVisContext: undefined,
};

const getStateService = (options: Omit<UnifiedHistogramStateOptions, 'services'>) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ describe('UnifiedHistogramStateService', () => {
totalHitsStatus: UnifiedHistogramFetchStatus.uninitialized,
totalHitsResult: undefined,
currentSuggestion: undefined,
externalVisContext: undefined,
};

it('should initialize state with default values', () => {
Expand Down
1 change: 1 addition & 0 deletions src/plugins/unified_histogram/public/mocks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export const createMockUnifiedHistogramApi = () => {
const api: UnifiedHistogramApi = {
state$: new Observable(),
setChartHidden: jest.fn(),
setExternalVisContext: jest.fn(),
setTopPanelHeight: jest.fn(),
setBreakdownField: jest.fn(),
setTimeInterval: jest.fn(),
Expand Down

0 comments on commit 2033a6d

Please sign in to comment.