Skip to content

Commit

Permalink
Update Cypress tests. (#2812)
Browse files Browse the repository at this point in the history
* Add goToTaskList() before user logout.

* Add wait() for the dropdown menu transition
  • Loading branch information
dvkruchinin authored Feb 16, 2021
1 parent 5504ba1 commit daedff4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (C) 2020 Intel Corporation
// Copyright (C) 2020-2021 Intel Corporation
//
// SPDX-License-Identifier: MIT

Expand Down Expand Up @@ -112,6 +112,7 @@ context('Base actions on the project', () => {
cy.get('.cvat-constructor-viewer').should('not.exist');
});
it('Logout first user, register second user, tries to create project and logout.', () => {
cy.goToTaskList();
cy.logout();
cy.goToRegisterPage();
cy.userRegistration(firstName, lastName, userName, emailAddr, password);
Expand Down Expand Up @@ -141,6 +142,7 @@ context('Base actions on the project', () => {
cy.goToTaskList();
cy.contains('strong', taskName.secondTask).should('not.exist');
cy.openTask(taskName.firstTask);
cy.goToTaskList();
cy.logout(userName);
});
it('Delete the project. Deleted project not exist. Checking the availability of tasks.', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ context('Settings. "Player speed" option.', () => {
function changePlayerSpeed(speed) {
cy.openSettings();
cy.get('.cvat-player-settings-speed').within(() => {
cy.get('.cvat-player-settings-speed-select').click();
cy.get('.cvat-player-settings-speed-select').click().wait(300); // Wait for the dropdown menu transition.
});
cy.get(`.cvat-player-settings-speed-${speed}`).click();
cy.get('.cvat-player-settings-speed-select').should(
Expand Down

0 comments on commit daedff4

Please sign in to comment.