From 860887129c48d0058731d56f333b3600f1d363ec Mon Sep 17 00:00:00 2001 From: guoqqqi <979918879@qq.com> Date: Thu, 25 Feb 2021 16:44:20 +0800 Subject: [PATCH 1/2] fix: update code --- web/yarn.lock | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/web/yarn.lock b/web/yarn.lock index c956847dc7..e9f189d94f 100644 --- a/web/yarn.lock +++ b/web/yarn.lock @@ -2824,6 +2824,13 @@ resolved "https://registry.yarnpkg.com/@types/range-parser/-/range-parser-1.2.3.tgz#7ee330ba7caafb98090bece86a5ee44115904c2c" integrity sha512-ewFXqrQHlFsgc09MK5jP5iR7vumV/BYayNC6PgJO2LPe8vrnNFyjQjSppfEngITi0qvfKtzFvgKymGheFM9UOA== +"@types/react-copy-to-clipboard@^5.0.0": + version "5.0.0" + resolved "https://registry.yarnpkg.com/@types/react-copy-to-clipboard/-/react-copy-to-clipboard-5.0.0.tgz#38b035ca0c28334d3e0efaf3f319b81eea9690cd" + integrity sha512-faUg6Kx3Dfv0MBIcs+xzIptlRtjEVSaNjqyC14YAp4UwSiTHghnKtBOt9ERRTZZJfoJgnw10tomVaqG86GzdAw== + dependencies: + "@types/react" "*" + "@types/react-dom@^16.8.4", "@types/react-dom@^16.9.8": version "16.9.10" resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-16.9.10.tgz#4485b0bec3d41f856181b717f45fd7831101156f" From 75940b98ded68da53c55c4ad33df742d9c19d064 Mon Sep 17 00:00:00 2001 From: guoqqqi <979918879@qq.com> Date: Thu, 4 Mar 2021 16:40:52 +0800 Subject: [PATCH 2/2] fix: CI error --- web/cypress/integration/route/import_export_route.spec.js | 7 +++---- web/cypress/integration/route/search-route.spec.js | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/web/cypress/integration/route/import_export_route.spec.js b/web/cypress/integration/route/import_export_route.spec.js index d8730cf4a7..dcf9c1a2ce 100644 --- a/web/cypress/integration/route/import_export_route.spec.js +++ b/web/cypress/integration/route/import_export_route.spec.js @@ -42,6 +42,7 @@ context('import and export routes', () => { cy.login(); cy.fixture('selector.json').as('domSelector'); + cy.fixture('data.json').as('data'); cy.fixture('export-route-dataset.json').as('exportFile'); }); it('should create route1 and route2', function () { @@ -129,8 +130,7 @@ context('import and export routes', () => { .click(); cy.contains('button', componentLocaleUS['component.global.confirm']).click(); cy.get(this.domSelector.notification).should( - 'contain', - `${componentLocaleUS['component.global.delete']} ${menuLocaleUS['menu.routes']} ${componentLocaleUS['component.status.success']}`, + 'contain', this.data.deleteRouteSuccess ); } }); @@ -154,8 +154,7 @@ context('import and export routes', () => { cy.contains(componentLocaleUS['component.global.cancel']).click(); } else { cy.get(this.domSelector.notification).should( - 'contain', - `${routeLocaleUS['page.route.button.importOpenApi']} ${componentLocaleUS['component.status.success']}`, + 'contain', 'Success' ); cy.get(this.domSelector.notificationCloseIcon).click(); // delete route just imported diff --git a/web/cypress/integration/route/search-route.spec.js b/web/cypress/integration/route/search-route.spec.js index d6ffa17bd3..be3e0c2317 100644 --- a/web/cypress/integration/route/search-route.spec.js +++ b/web/cypress/integration/route/search-route.spec.js @@ -103,7 +103,7 @@ context('Create and Search Route', () => { // search one label cy.get(this.domSelector.refresh).click(); cy.get(this.domSelector.labelSelector).click(); - cy.get(this.domSelector.dropdown).within(() => { + cy.get(this.domSelector.dropdown).should('be.visible').within(() => { cy.contains(data.value0).click(); }); cy.contains('Search').click();