Skip to content

Commit

Permalink
use info instead of warning when export contains excluded objects
Browse files Browse the repository at this point in the history
  • Loading branch information
pgayvallet committed Jun 15, 2021
1 parent 16ac169 commit 55f03c2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ describe('SavedObjectsTable', () => {
});
});

it('should display a warning if the export contains excluded objects', async () => {
it('should display a specific message if the export contains excluded objects', async () => {
const mockSelectedSavedObjects = [
{ id: '1', type: 'index-pattern' },
{ id: '3', type: 'dashboard' },
Expand Down Expand Up @@ -344,7 +344,7 @@ describe('SavedObjectsTable', () => {
await component.instance().onExport(true);

expect(fetchExportObjectsMock).toHaveBeenCalledWith(http, mockSelectedSavedObjects, true);
expect(notifications.toasts.addWarning).toHaveBeenCalledWith({
expect(notifications.toasts.addSuccess).toHaveBeenCalledWith({
title:
'Your file is downloading in the background. ' +
'Some objects were excluded from the export. ' +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ export class SavedObjectsTable extends Component<SavedObjectsTableProps, SavedOb
});
}
if (exportDetails.excludedObjects.length > 0) {
return notifications.toasts.addWarning({
return notifications.toasts.addSuccess({
title: i18n.translate(
'savedObjectsManagement.objectsTable.export.successWithExcludedObjectsNotification',
{
Expand Down

0 comments on commit 55f03c2

Please sign in to comment.