-
Notifications
You must be signed in to change notification settings - Fork 112
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: yujin-emma <[email protected]>
- Loading branch information
1 parent
4ddffc9
commit fd321fb
Showing
8 changed files
with
181 additions
and
4,603 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
185 changes: 0 additions & 185 deletions
185
...tegration/core-opensearch-dashboards/opensearch-dashboards/mds_import_export_test.spec.js
This file was deleted.
Oops, something went wrong.
62 changes: 62 additions & 0 deletions
62
cypress/integration/core-opensearch-dashboards/opensearch-dashboards/mds_import_test.spec.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
import { MiscUtils } from '@opensearch-dashboards-test/opensearch-dashboards-test-library'; | ||
import { CURRENT_TENANT } from '../../../utils/commands'; | ||
import 'cypress-file-upload'; | ||
|
||
const miscUtils = new MiscUtils(cy); | ||
|
||
if (Cypress.env('DATASOURCE_MANAGEMENT_ENABLED')) { | ||
let dataSourceTitle; | ||
|
||
describe('import saved object test', () => { | ||
before(() => { | ||
// Go to the saved object page | ||
cy.deleteAllDataSources(); | ||
cy.wait(1000); | ||
|
||
cy.deleteAllSavedObjects(); | ||
miscUtils.visitPage('app/management/opensearch-dashboards/objects'); | ||
|
||
CURRENT_TENANT.newTenant = 'global'; | ||
cy.wait(1000); | ||
|
||
// create data source | ||
cy.createDataSourceNoAuth().then((result) => { | ||
dataSourceTitle = result[1]; | ||
}); | ||
cy.reload(true); | ||
cy.wait(1000); | ||
}); | ||
|
||
after(() => { | ||
cy.deleteAllSavedObjects(); | ||
}); | ||
|
||
it('can import saved objects from ndjson file and create new copies', () => { | ||
cy.uploadSavedObjectsToDataSource( | ||
'createNewCopiesEnabled', | ||
'', | ||
dataSourceTitle | ||
); | ||
}); | ||
it('can import saved objects from ndjson file and automatically override conflict', () => { | ||
cy.uploadSavedObjectsToDataSource( | ||
'createNewCopiesDisabled', | ||
'overwriteEnabled', | ||
dataSourceTitle | ||
); | ||
}); | ||
|
||
it('can import saved objects from ndjson file and request action when conflict exit', () => { | ||
cy.uploadSavedObjectsToDataSource( | ||
'createNewCopiesDisabled', | ||
'overwriteDisabled', | ||
dataSourceTitle | ||
); | ||
}); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.