|
|
|
@ -75,7 +75,11 @@ it('creates new visualization when clicked Add visualization', () => { |
|
|
|
|
fireEvent.click(screen.getByRole('button', { name: 'Add visualization' })); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
expect(reportInteraction).toHaveBeenCalledWith('dashboards_emptydashboard_clicked', { item: 'add_visualization' }); |
|
|
|
|
expect(reportInteraction).toHaveBeenCalledWith( |
|
|
|
|
'dashboards_emptydashboard_clicked', |
|
|
|
|
{ item: 'add_visualization' }, |
|
|
|
|
undefined |
|
|
|
|
); |
|
|
|
|
expect(locationService.partial).toHaveBeenCalled(); |
|
|
|
|
expect(onCreateNewPanel).toHaveBeenCalled(); |
|
|
|
|
}); |
|
|
|
@ -87,7 +91,11 @@ it('open import dashboard when clicked Import dashboard', () => { |
|
|
|
|
fireEvent.click(screen.getByRole('button', { name: 'Import dashboard' })); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
expect(reportInteraction).toHaveBeenCalledWith('dashboards_emptydashboard_clicked', { item: 'import_dashboard' }); |
|
|
|
|
expect(reportInteraction).toHaveBeenCalledWith( |
|
|
|
|
'dashboards_emptydashboard_clicked', |
|
|
|
|
{ item: 'import_dashboard' }, |
|
|
|
|
undefined |
|
|
|
|
); |
|
|
|
|
expect(onImportDashboard).toHaveBeenCalled(); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
@ -98,7 +106,11 @@ it('adds a library panel when clicked Add library panel', () => { |
|
|
|
|
fireEvent.click(screen.getByRole('button', { name: 'Add library panel' })); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
expect(reportInteraction).toHaveBeenCalledWith('dashboards_emptydashboard_clicked', { item: 'import_from_library' }); |
|
|
|
|
expect(reportInteraction).toHaveBeenCalledWith( |
|
|
|
|
'dashboards_emptydashboard_clicked', |
|
|
|
|
{ item: 'import_from_library' }, |
|
|
|
|
undefined |
|
|
|
|
); |
|
|
|
|
expect(locationService.partial).not.toHaveBeenCalled(); |
|
|
|
|
expect(onAddLibraryPanel).toHaveBeenCalled(); |
|
|
|
|
}); |
|
|
|
|