Skip to content

Commit

Permalink
Update the app with a new skill level (DevOps)
Browse files Browse the repository at this point in the history
And update a test according to the app change.
  • Loading branch information
wlsf82 committed Jun 22, 2024
1 parent cf2c942 commit 025963b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cypress/e2e/checklist.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ describe('Cypress Skills Checklist', () => {
cy.contains('footer', '0%').should('not.exist')
})

it('checking all checkboxes leads to 100% completion and advanced - Sr. level', () => {
it('checking all checkboxes leads to 100% completion and DevOps level', () => {
cy.get('input[type="checkbox"]').check()

cy.contains('footer', '(100%) - Nível de habilidade: Avançado (Sr.)').should('be.visible')
cy.contains('footer', '(100%) - Nível de habilidade: DevOps').should('be.visible')
})
})

Expand Down
4 changes: 3 additions & 1 deletion src/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@ document.addEventListener('DOMContentLoaded', () => {
skillLevelElement.textContent = 'Iniciante (Jr.)'
} else if (percentage >= 50 && percentage < 75) {
skillLevelElement.textContent = 'Intermediário (Pleno)'
} else {
} else if (percentage >= 75 && percentage < 95) {
skillLevelElement.textContent = 'Avançado (Sr.)'
} else {
skillLevelElement.textContent = 'DevOps'
}
}

Expand Down

0 comments on commit 025963b

Please sign in to comment.