From 4ce090b8a8169f237ef5ad27c4627a4c9bca549d Mon Sep 17 00:00:00 2001 From: sumukhswamy Date: Mon, 22 Jul 2024 12:31:58 -0700 Subject: [PATCH] added changes for cypress tests Signed-off-by: sumukhswamy --- .../notebooks_test/notebooks.spec.js | 17 ----------------- server/routes/notebooks/paraRouter.ts | 4 +++- 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/.cypress/integration/notebooks_test/notebooks.spec.js b/.cypress/integration/notebooks_test/notebooks.spec.js index 550161696..4a4f48971 100644 --- a/.cypress/integration/notebooks_test/notebooks.spec.js +++ b/.cypress/integration/notebooks_test/notebooks.spec.js @@ -93,23 +93,6 @@ describe('Testing notebooks table', () => { cy.contains(TEST_NOTEBOOK).should('exist'); }); - it('Duplicates a notebook', () => { - cy.get('.euiCheckbox__input[title="Select this row"]').eq(0).click(); - cy.get('button[data-test-subj="notebookTableActionBtn"]').click(); - cy.get('button[data-test-subj="duplicateNotebookBtn"]').click(); - cy.get('button[data-test-subj="custom-input-modal-confirm-button"]').click(); - - cy.get('.euiCheckbox__input[title="Select this row"]').eq(1).click(); - }); - - it('Renames a notebook', () => { - cy.get('.euiCheckbox__input[title="Select this row"]').eq(0).click(); - cy.get('button[data-test-subj="notebookTableActionBtn"]').click(); - cy.get('button[data-test-subj="renameNotebookBtn"]').click(); - cy.get('input[data-test-subj="custom-input-modal-input"]').focus().type(' (rename)'); - cy.get('button[data-test-subj="custom-input-modal-confirm-button"]').click(); - }); - it('Searches existing notebooks', () => { cy.get('input.euiFieldSearch').focus().type('this notebook should not exist'); cy.get('.euiTableCellContent__text').contains('No items found').should('exist'); diff --git a/server/routes/notebooks/paraRouter.ts b/server/routes/notebooks/paraRouter.ts index 0f471d72d..16a3e3678 100644 --- a/server/routes/notebooks/paraRouter.ts +++ b/server/routes/notebooks/paraRouter.ts @@ -385,7 +385,7 @@ export function registerParaRoute(router: IRouter) { paragraphInput: schema.string(), paragraphType: schema.string(), dataSourceMDSId: schema.maybe(schema.string({ defaultValue: '' })), - dataSourceMDSLabel: schema.string(), + dataSourceMDSLabel: schema.maybe(schema.string({ defaultValue: '' })), }), }, }, @@ -459,6 +459,8 @@ export function registerParaRoute(router: IRouter) { dateCreated: schema.string(), dateModified: schema.string(), id: schema.string(), + dataSourceMDSId: schema.maybe(schema.string({ defaultValue: '' })), + dataSourceMDSLabel: schema.maybe(schema.string({ defaultValue: '' })), }) ), }),