-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
EVOFORGE\dimay
committed
Dec 22, 2023
1 parent
2fc86c2
commit 748bfca
Showing
3 changed files
with
93 additions
and
250 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -381,58 +381,24 @@ describe('Projects Modal Management Tests', () => { | |
}); | ||
|
||
it('project users input field submits on enter', () => { | ||
cy.request('POST', '/app/projects/my_project_123', { | ||
projectId: 'my_project_123', | ||
name: 'My Project 123' | ||
}); | ||
|
||
cy.request('POST', '/admin/projects/my_project_123/subjects/subj1', { | ||
projectId: 'my_project_123', | ||
subjectId: 'subj1', | ||
name: 'Subject 1' | ||
}); | ||
cy.request('POST', `/admin/projects/my_project_123/subjects/subj1/skills/skill1`, { | ||
projectId: 'my_project_123', | ||
subjectId: 'subj1', | ||
skillId: 'skill1', | ||
name: `This is 1`, | ||
type: 'Skill', | ||
pointIncrement: 100, | ||
numPerformToCompletion: 10, | ||
pointIncrementInterval: 0, | ||
numMaxOccurrencesIncrementInterval: -1, | ||
version: 0, | ||
}); | ||
|
||
cy.createProject(1) | ||
cy.createSubject(1, 1) | ||
cy.createSkill(1, 1, 1) | ||
const now = dayjs(); | ||
cy.reportSkill('my_project_123', 1, '[email protected]', now.subtract(1, 'year') | ||
cy.reportSkill('proj1', 1, '[email protected]', now.subtract(1, 'year') | ||
.format('YYYY-MM-DD HH:mm'), false); | ||
cy.reportSkill('my_project_123', 1, '[email protected]', now.subtract(1, 'year') | ||
cy.reportSkill('proj1', 1, '[email protected]', now.subtract(1, 'year') | ||
.format('YYYY-MM-DD HH:mm'), false); | ||
cy.reportSkill('my_project_123', 1, '[email protected]', now.subtract(1, 'year') | ||
cy.reportSkill('proj1', 1, '[email protected]', now.subtract(1, 'year') | ||
.format('YYYY-MM-DD HH:mm'), false); | ||
cy.reportSkill('my_project_123', 1, '[email protected]', now.subtract(1, 'year') | ||
.format('YYYY-MM-DD HH:mm'), false); | ||
|
||
cy.intercept('GET', '/admin/projects/my_project_123') | ||
.as('loadProj'); | ||
cy.intercept('GET', '/api/projects/Inception/level') | ||
.as('loadInception'); | ||
cy.intercept('GET', '/admin/projects/my_project_123/users**') | ||
.as('loadUsers'); | ||
cy.visit('/administrator/projects/my_project_123'); | ||
cy.wait('@loadProj'); | ||
cy.wait('@loadInception'); | ||
cy.get('[data-cy="inception-button"]').contains('Level'); | ||
cy.get('[data-cy=nav-Users]') | ||
.click(); | ||
cy.wait('@loadUsers'); | ||
cy.get('[data-cy=usersTable_viewDetailsBtn]') | ||
.should('have.length', 4); | ||
cy.visit('/administrator/projects/proj1/users'); | ||
cy.get('[data-cy="skillsBTableTotalRows"]').should('have.text', '3'); | ||
cy.get('[data-cy=users-skillIdFilter]').should('be.visible') | ||
cy.get('[data-cy=users-skillIdFilter]') | ||
.type('user1{enter}'); | ||
cy.wait('@loadUsers'); | ||
cy.get('[data-cy=usersTable_viewDetailsBtn]') | ||
.should('have.length', 1); | ||
cy.get('[data-cy="skillsBTableTotalRows"]').should('have.text', '1'); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters