Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests for admin panel #295

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

tests for admin panel #295

wants to merge 1 commit into from

Conversation

TetianaFomina
Copy link
Collaborator

No description provided.

Copy link

vercel bot commented Mar 12, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
react-boilerplate ✅ Ready (Inspect) Visit Preview Mar 12, 2024 10:19am

expect(request.response?.statusCode).to.equal(200);
});
cy.wait(3000);
cy.get('[data-testid="first-name"] input').should(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you consider:

    cy.getBySel('first-name').children('input').should(

?

expect(request.response?.statusCode).to.equal(200);
});
cy.getBySel("users-list").should("be.visible");
cy.wait(3000);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without cy.wait(3000); doesn't work?

@@ -65,6 +65,7 @@ function SelectInputRaw<T extends object>(
{props.options.map((option) => (
<MenuItem
key={option[props.keyValue]?.toString()}
data-testid={option[props.keyValue]?.toString()}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's add a prefixed option because we can have more than one select box on the page, which can cause problems.

Suggested change
data-testid={option[props.keyValue]?.toString()}
data-testid={`${props.testId}-option-${option[props.keyValue]?.toString()}`}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants