Yuki Takei 3 anni fa
parent
commit
436c14c498

+ 1 - 1
packages/app/src/components/User/UserInfo.tsx

@@ -19,7 +19,7 @@ export const UserInfo = (props: UserInfoProps): JSX.Element => {
   }
 
   return (
-    <div className={`${styles['grw-users-info']} grw-users-info d-flex align-items-center d-edit-none mb-5 pb-3 border-bottom`}>
+    <div className={`${styles['grw-users-info']} grw-users-info d-flex align-items-center d-edit-none mb-5 pb-3 border-bottom`} data-testid="grw-users-info">
       <UserPicture user={author} />
       <div className="users-meta">
         <h1 className="user-page-name">

+ 4 - 3
packages/app/test/cypress/integration/60-home/60-home--home.spec.ts

@@ -14,21 +14,22 @@ context('Access Home', () => {
     // open PersonalDropdown
     cy.waitUntil(() => {
       // do
-      cy.get('.grw-personal-dropdown').should('be.visible').click();
+      cy.getByTestid('personal-dropdown-button').should('be.visible').click();
       // wait until
       return cy.getByTestid('grw-personal-dropdown-menu-user-home').then($elem => $elem.is(':visible'));
     });
     // click the Home button
     cy.getByTestid('grw-personal-dropdown-menu-user-home').should('be.visible').click();
 
-    cy.waitUntilSkeletonDisappear();
-    cy.collapseSidebar(true);
+    cy.getByTestid('grw-users-info').should('be.visible')
 
     // for check download toc data
     // https://redmine.weseek.co.jp/issues/111384
     // cy.get('.toc-link').should('be.visible');
 
     // same screenshot is taken in access-to-page.spec
+    cy.collapseSidebar(true);
+    cy.waitUntilSkeletonDisappear();
     cy.screenshot(`${ssPrefix}-visit-home`);
   });