mirror of
https://github.com/sartography/spiff-arena.git
synced 2025-03-01 09:30:46 +00:00
some updates for NDR_PP1 cypress tests w/ burnettk
This commit is contained in:
parent
661fe7fef4
commit
b1d27cec75
2
spiffworkflow-frontend/.gitignore
vendored
2
spiffworkflow-frontend/.gitignore
vendored
@ -33,3 +33,5 @@ cypress/screenshots
|
|||||||
|
|
||||||
# Editors
|
# Editors
|
||||||
.idea
|
.idea
|
||||||
|
|
||||||
|
/cypress.env
|
||||||
|
@ -30,6 +30,14 @@ if [[ -z "${CYPRESS_SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK:-}" ]]; then
|
|||||||
export CYPRESS_SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK=true
|
export CYPRESS_SPIFFWORKFLOW_FRONTEND_AUTH_WITH_KEYCLOAK=true
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ -f cypress.env ]]; then
|
||||||
|
# shellcheck disable=1091
|
||||||
|
source cypress.env
|
||||||
|
else
|
||||||
|
>&2 echo "ERROR: This requires a cypress.env file to run. You may be able to use generate_pp1_cypress_env_configs."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
cypress_run_file="/var/tmp/cypress_run"
|
cypress_run_file="/var/tmp/cypress_run"
|
||||||
echo "Recording stats to ${cypress_run_file}"
|
echo "Recording stats to ${cypress_run_file}"
|
||||||
|
|
||||||
@ -44,7 +52,6 @@ for attempt in $(seq 1 "$ATTEMPTS" ); do
|
|||||||
|
|
||||||
start_time=$(date +%s)
|
start_time=$(date +%s)
|
||||||
success="false"
|
success="false"
|
||||||
# spec_pattern="cypress/pilot/**/*.cy.{js,jsx,ts,tsx}"
|
|
||||||
spec_pattern="cypress/pilot/**/*.cy.{js,jsx,ts,tsx}"
|
spec_pattern="cypress/pilot/**/*.cy.{js,jsx,ts,tsx}"
|
||||||
if ./node_modules/.bin/cypress "$command" -c specPattern="${spec_pattern}" --e2e --browser chrome "$@"; then
|
if ./node_modules/.bin/cypress "$command" -c specPattern="${spec_pattern}" --e2e --browser chrome "$@"; then
|
||||||
success="true"
|
success="true"
|
||||||
|
@ -93,7 +93,7 @@ describe.only('Software and Licenses Path - Without Files', () => {
|
|||||||
Cypress._.times(1, () => {
|
Cypress._.times(1, () => {
|
||||||
|
|
||||||
//Everyone approves with CP
|
//Everyone approves with CP
|
||||||
it('Everyone approves with CP', () => {
|
it.only('Everyone approves with CP', () => {
|
||||||
let username = Cypress.env('requestor_username');
|
let username = Cypress.env('requestor_username');
|
||||||
let password = Cypress.env('requestor_password');
|
let password = Cypress.env('requestor_password');
|
||||||
cy.log('=====username : ' + username);
|
cy.log('=====username : ' + username);
|
||||||
@ -103,23 +103,10 @@ describe.only('Software and Licenses Path - Without Files', () => {
|
|||||||
cy.visit('/');
|
cy.visit('/');
|
||||||
|
|
||||||
cy.contains('Start New +').click();
|
cy.contains('Start New +').click();
|
||||||
cy.contains('Request Goods or Services');
|
cy.contains('Request Goods or Services').click();
|
||||||
|
|
||||||
cy.runPrimaryBpmnFile(true);
|
cy.runPrimaryBpmnFile(true);
|
||||||
|
|
||||||
/* cy.contains('Please select the type of request to start the process.');
|
|
||||||
// wait a second to ensure we can click the radio button
|
|
||||||
|
|
||||||
cy.wait(2000);
|
|
||||||
cy.get('input#root-procurement').click();
|
|
||||||
cy.wait(2000);
|
|
||||||
|
|
||||||
|
|
||||||
cy.get('button')
|
|
||||||
.contains(/^Submit$/)
|
|
||||||
.click();
|
|
||||||
*/
|
|
||||||
|
|
||||||
cy.contains(
|
cy.contains(
|
||||||
'Request Goods or Services',
|
'Request Goods or Services',
|
||||||
{ timeout: 60000 }
|
{ timeout: 60000 }
|
||||||
|
@ -63,6 +63,7 @@ Cypress.Commands.add('login', (username, password) => {
|
|||||||
|
|
||||||
Cypress.Commands.add('logout', (_selector, ..._args) => {
|
Cypress.Commands.add('logout', (_selector, ..._args) => {
|
||||||
cy.get('#user-profile-toggletip').click();
|
cy.get('#user-profile-toggletip').click();
|
||||||
|
cy.wait(2000);
|
||||||
cy.getBySel('logout-button').click();
|
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
|
// otherwise we can click logout, quickly load the next page, and the javascript
|
||||||
|
Loading…
x
Reference in New Issue
Block a user