juzhiyuan commented on a change in pull request #1432: URL: https://github.com/apache/apisix-dashboard/pull/1432#discussion_r570740379
########## File path: web/cypress/fixtures/selector.json ########## @@ -1,49 +1,46 @@ { - "switcher": ".ant-space-align-center", + "languageSwitcher": ".ant-space-align-center", "dropdown": ".rc-virtual-list", "notification": ".ant-notification-notice-message", "drawerBody": ".ant-drawer-wrapper-body", "notificationCloseIcon": ".ant-notification-close-icon", "notificationDesc": ".ant-notification-notice-description", - "pluginsCard": ".ant-card", + "pluginCard": ".ant-card", "pageContent": ".ant-pro-page-container", "tableCell": ".ant-table-cell", "empty": ".ant-empty-normal", "refresh": ".anticon-reload", "codemirror": ".CodeMirror", - "switch": "#disable", - "deleteBtn": ".ant-btn-dangerous", + "disabledSwitcher": "#disable", + "deleteButton": ".ant-btn-dangerous", "name": "#name", "nodes_0_host": "#nodes_0_host", "upstream_id": "#upstream_id", "input": ":input", - "custom_upstream": "[title=Custom]", - "title_name": "[title=Name]", - "test_service": "[title=test_service]", + "nameSelector": "[title=Name]", + "serviceSelector": "[title=test_service]", "description": "#desc", - "search_name": "[title=Name]", - "upstream_selector": "[data-cy=upstream_selector]", + "upstreamSelector": "[data-cy=upstream_selector]", - "file": "[type=file]", + "fileSelector": "[type=file]", "fileTypeRadio": "[type=radio]", - "uriInput": "#debugUri", + "debugUri": "#debugUri", Review comment: selector? input box? or something else? ########## File path: web/cypress/integration/route/search-route.spec.js ########## @@ -77,21 +77,21 @@ context('Create and Search Route', () => { cy.visit('/'); cy.contains('Route').click(); // full match - cy.get(this.domSelector.searchName).type(data.test1); + cy.get(this.domSelector.nameSelector).type(data.test1); cy.contains('Search').click(); cy.contains(data.test1).siblings().should('contain', data.desc1); cy.contains(data.test0).should('not.exist'); cy.contains(data.test2).should('not.exist'); // partial match cy.reload(); - cy.get(this.domSelector.searchName).type(data.test); + cy.get(this.domSelector.nameSelector).type(data.test); cy.contains('Search').click(); cy.contains(data.test0).siblings().should('contain', data.desc0); cy.contains(data.test1).siblings().should('contain', data.desc1); cy.contains(data.test2).siblings().should('contain', data.desc2); // no match cy.reload(); - cy.get(this.domSelector.searchName).type(data.testx); + cy.get(this.domSelector.nameSelector).type(data.testx); Review comment: what's name selector? it seems like a `nameInput` here. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org