소스 검색

add should be visible

Yohei-Shiina 3 년 전
부모
커밋
8cbdf3b40c
1개의 변경된 파일6개의 추가작업 그리고 6개의 파일을 삭제
  1. 6 6
      packages/app/test/cypress/integration/20-basic-features/access-to-page.spec.ts

+ 6 - 6
packages/app/test/cypress/integration/20-basic-features/access-to-page.spec.ts

@@ -145,13 +145,13 @@ context('Access to Template Editing Mode', () => {
   it('Access to Template Editor mode for only child pages successfully', () => {
     cy.visit('/Sandbox/Bootstrap4', {  });
     cy.get('#grw-subnav-container', { timeout: 30000 }).within(() => {
-      cy.getByTestid('open-page-item-control-btn', { timeout: 30000 }).click();
-      cy.getByTestid('open-page-template-modal-btn', { timeout: 30000 }).click();
+      cy.getByTestid('open-page-item-control-btn', { timeout: 30000 }).should('be.visible').click();
+      cy.getByTestid('open-page-template-modal-btn', { timeout: 30000 }).should('be.visible').click();
     });
 
     cy.getByTestid('page-template-modal').should('be.visible')
     cy.screenshot(`${ssPrefix}-open-page-template-bootstrap4`);
-    cy.getByTestid('template-button-children', { timeout: 30000 }).click();
+    cy.getByTestid('template-button-children', { timeout: 30000 }).should('be.visible').click();
     cy.get('.grw-skelton', { timeout: 30000 }).should('not.exist').then(()=>{
       cy.getByTestid('navbar-editor', { timeout: 30000 }).should('be.visible').then(()=>{
         cy.url().should('include', '/_template#edit');
@@ -163,12 +163,12 @@ context('Access to Template Editing Mode', () => {
   it('Access to Template Editor mode including decendants successfully', () => {
     cy.visit('/Sandbox/Bootstrap4', {  });
     cy.get('#grw-subnav-container', { timeout: 30000 }).within(() => {
-      cy.getByTestid('open-page-item-control-btn', { timeout: 30000 }).click();
-      cy.getByTestid('open-page-template-modal-btn', { timeout: 30000 }).click();
+      cy.getByTestid('open-page-item-control-btn', { timeout: 30000 }).should('be.visible').click();
+      cy.getByTestid('open-page-template-modal-btn', { timeout: 30000 }).should('be.visible').click();
     });
 
     cy.getByTestid('page-template-modal').should('be.visible')
-    cy.getByTestid('template-button-decendants').click();
+    cy.getByTestid('template-button-decendants').should('be.visible').click();
     cy.get('.grw-skelton', { timeout: 30000 }).should('not.exist').then(()=>{
       cy.getByTestid('navbar-editor', { timeout: 30000 }).should('be.visible').then(()=>{
         cy.url().should('include', '/__template#edit');