Skip to content

Commit

Permalink
Uppercase cypress env variable name
Browse files Browse the repository at this point in the history
Since on GitHub Actions secrets, they are always uppercase.
  • Loading branch information
wlsf82 committed Jan 17, 2024
1 parent dd82bea commit 7ba5ee7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cypress.env.example.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"password": "your-secret-password-here"
"PASSWORD": "your-secret-password-here"
}
4 changes: 2 additions & 2 deletions cypress/e2e/playground.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -158,14 +158,14 @@ describe('Cypress Playground', () => {

it('types a password without leaking it, shows it, and hides it again', () => {
cy.get('#password-input input[type="password"]')
.type(Cypress.env('password'), { log: false })
.type(Cypress.env('PASSWORD'), { log: false })

cy.get('#password-input input[type="checkbox"').check()

cy.get('#password-input input[type="password"]').should('not.exist')
cy.get('#password-input input[type="text"]')
.should('be.visible')
.and('have.value', Cypress.env('password'))
.and('have.value', Cypress.env('PASSWORD'))

cy.get('#password-input input[type="checkbox"').uncheck()

Expand Down

0 comments on commit 7ba5ee7

Please sign in to comment.