corrected cypress env var

This commit is contained in:
jasquat 2023-02-16 13:31:08 -05:00
parent a98892be32
commit 8a421bfb2c
2 changed files with 3 additions and 3 deletions

View File

@ -101,7 +101,7 @@ jobs:
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
# pass GitHub token to allow accurately detecting a build vs a re-run build
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK: "true"
CYPRESS_SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK: "true"
- name: get_backend_logs_from_docker_compose
if: failure()
working-directory: ./spiffworkflow-backend

View File

@ -47,7 +47,7 @@ Cypress.Commands.add('login', (selector, ...args) => {
const password = Cypress.env('SPIFFWORKFLOW_FRONTEND_PASSWORD') || 'ciadmin1';
cy.get('#username').type(username);
cy.get('#password').type(password);
if (Cypress.env('SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK') === 'true') {
if (Cypress.env('SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK') === true) {
cy.get('#kc-login').click();
} else {
cy.get('#spiff-login-button').click();
@ -57,7 +57,7 @@ Cypress.Commands.add('login', (selector, ...args) => {
Cypress.Commands.add('logout', (selector, ...args) => {
cy.getBySel('logout-button').click();
if (Cypress.env('SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK') === 'true') {
if (Cypress.env('SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK') === true) {
// otherwise we can click logout, quickly load the next page, and the javascript
// doesn't have time to actually sign you out
cy.contains('Sign in to your account');