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

Solution #244

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

Solution #244

wants to merge 1 commit into from

Conversation

pulchoilya
Copy link

No description provided.

Copy link

@Ivan-Shvorak Ivan-Shvorak left a comment

Choose a reason for hiding this comment

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

Please check the comments


describe('Web Tables page', () => {
it('', () => {
beforeEach(() => {

Choose a reason for hiding this comment

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

add empty lines between beforeEach and all tests

Copy link
Author

Choose a reason for hiding this comment

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

beforeEach(() => {
cy.visit('https://demoqa.com/webtables');
});
it('should check Pagination', () => {

Choose a reason for hiding this comment

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

Please consider that describe + test name should create summary together - in this case we have
Web Tables page + should check Pagination // Web Tables shouldn't check pagination.

Better to write
Web Tables page + should allow user to change page

Check and fix everywhere

Copy link
Author

Choose a reason for hiding this comment

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

cy.visit('https://demoqa.com/webtables');
});
it('should check Pagination', () => {
cy.get('.rt-tbody .rt-tr-group').should('have.length', 10);

Choose a reason for hiding this comment

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

Try to use more descriptive selectors everywhere

Copy link
Author

Choose a reason for hiding this comment

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

сhange

cy.get('.rt-tbody .rt-tr-group').should('have.length', 10);
cy.get('.-next').should('be.visible').and('not.be.disabled');
cy.get('img[src="/images/Toolsqa.jpg"]').should('exist');
cy.url().should('eq', 'https://demoqa.com/webtables');

Choose a reason for hiding this comment

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

Not sure what this assert is doing here

Copy link
Author

Choose a reason for hiding this comment

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

change

cy.get(`.rt-noData`).should('contain', 'No rows found');
});
it('should Find a worker in the search field and edit it.', () => {
cy.get('input#searchBox').type('Cierra');

Choose a reason for hiding this comment

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

add search keyword to const

Copy link
Author

Choose a reason for hiding this comment

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

add

});
it('should Find a worker in the search field and edit it.', () => {
cy.get('input#searchBox').type('Cierra');
cy.get('input#searchBox').clear();

Choose a reason for hiding this comment

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

Where do we have asserts to check search results?

@pulchoilya pulchoilya requested a review from Ivan-Shvorak August 6, 2024 09:11
Copy link

@VikVolSen VikVolSen left a comment

Choose a reason for hiding this comment

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

Good job!

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.

3 participants