Wrapped up testing and now ready for merge
Configures the pipelines to utilize regression testing, increases the total shards for automated testing, and corrects the logic for retrieving the branch name to extract the JIRA card number.
This commit is contained in:
parent
a9682c960d
commit
e2556b07bb
3 changed files with 7 additions and 6 deletions
|
|
@ -16,9 +16,9 @@ variables:
|
||||||
- name: imageTag
|
- name: imageTag
|
||||||
value: '$(Build.BuildId)'
|
value: '$(Build.BuildId)'
|
||||||
- name: totalShards
|
- name: totalShards
|
||||||
value: '2'
|
value: '4'
|
||||||
- name: IS_REGRESSION
|
- name: IS_REGRESSION
|
||||||
value: 'false'
|
value: 'true'
|
||||||
- name: JIRA_BOARD_ID
|
- name: JIRA_BOARD_ID
|
||||||
value: '845'
|
value: '845'
|
||||||
- name: JIRA_EPIC_KEY
|
- name: JIRA_EPIC_KEY
|
||||||
|
|
@ -30,6 +30,7 @@ stages:
|
||||||
- stage: TestPr
|
- stage: TestPr
|
||||||
displayName: Run Playwright Test
|
displayName: Run Playwright Test
|
||||||
jobs:
|
jobs:
|
||||||
|
# TODO: Change to ADO Playwright template
|
||||||
- template: temp/playwright-test.yml
|
- template: temp/playwright-test.yml
|
||||||
parameters:
|
parameters:
|
||||||
totalShards: ${{ variables.totalShards }}
|
totalShards: ${{ variables.totalShards }}
|
||||||
|
|
|
||||||
|
|
@ -64,7 +64,7 @@ stages:
|
||||||
jobs:
|
jobs:
|
||||||
- template: temp/playwright-test.yml
|
- template: temp/playwright-test.yml
|
||||||
parameters:
|
parameters:
|
||||||
totalShards: 4
|
totalShards: 2
|
||||||
targetUrl: $(BASE_URL)
|
targetUrl: $(BASE_URL)
|
||||||
dockerFileName: 'Dockerfile.playwright'
|
dockerFileName: 'Dockerfile.playwright'
|
||||||
isRegression: false
|
isRegression: false
|
||||||
|
|
|
||||||
|
|
@ -119,7 +119,7 @@ jobs:
|
||||||
IS_REGRESSION="${{ parameters.isRegression }}"
|
IS_REGRESSION="${{ parameters.isRegression }}"
|
||||||
echo "isRegression: $IS_REGRESSION";
|
echo "isRegression: $IS_REGRESSION";
|
||||||
if [[ "${{ parameters.isRegression }}" == "False" ]]; then
|
if [[ "${{ parameters.isRegression }}" == "False" ]]; then
|
||||||
branch_name=$(Build.SourceBranch) # TODO: Change back to PullRequest.SourceBranch
|
branch_name=$(PullRequest.SourceBranch)
|
||||||
echo "Retrieved branch name: '$branch_name'"
|
echo "Retrieved branch name: '$branch_name'"
|
||||||
JIRA_CARD_NUMBER="${branch_name##*/}"
|
JIRA_CARD_NUMBER="${branch_name##*/}"
|
||||||
echo "Extracted JIRA Card number: '$JIRA_CARD_NUMBER'"
|
echo "Extracted JIRA Card number: '$JIRA_CARD_NUMBER'"
|
||||||
|
|
@ -240,7 +240,7 @@ jobs:
|
||||||
arguments: '--no-cache --pull'
|
arguments: '--no-cache --pull'
|
||||||
- bash: |
|
- bash: |
|
||||||
printenv > "${{ parameters.envFileName }}"
|
printenv > "${{ parameters.envFileName }}"
|
||||||
branch_name=$(Build.SourceBranch) # TODO: Change back to PullRequest.SourceBranch
|
branch_name=$(PullRequest.SourceBranch)
|
||||||
echo "Retrieved branch name: '$branch_name'"
|
echo "Retrieved branch name: '$branch_name'"
|
||||||
JIRA_CARD_NUMBER="${branch_name##*/}"
|
JIRA_CARD_NUMBER="${branch_name##*/}"
|
||||||
echo "Extracted JIRA Card number: '$JIRA_CARD_NUMBER'"
|
echo "Extracted JIRA Card number: '$JIRA_CARD_NUMBER'"
|
||||||
|
|
@ -255,8 +255,8 @@ jobs:
|
||||||
bash -c "
|
bash -c "
|
||||||
echo 'Moving Playwright reports out of subfolders...'
|
echo 'Moving Playwright reports out of subfolders...'
|
||||||
find ./playwright-reports/ -mindepth 2 -type f -exec mv {} ./playwright-reports/ \;
|
find ./playwright-reports/ -mindepth 2 -type f -exec mv {} ./playwright-reports/ \;
|
||||||
echo 'Merging reports...'
|
|
||||||
echo 'Value of JIRA_CARD_NUMBER in bash -c command: $JIRA_CARD_NUMBER'
|
echo 'Value of JIRA_CARD_NUMBER in bash -c command: $JIRA_CARD_NUMBER'
|
||||||
|
echo 'Merging reports...'
|
||||||
JIRA_CARD_NUMBER='$JIRA_CARD_NUMBER' PLAYWRIGHT_JUNIT_OUTPUT_DIR='/app/test-results' PLAYWRIGHT_JUNIT_OUTPUT_NAME='junit_results.xml' npx --prefix $PLAYWRIGHT_PATH playwright merge-reports --config=$PLAYWRIGHT_PATH/playwright.config.ts ./playwright-reports
|
JIRA_CARD_NUMBER='$JIRA_CARD_NUMBER' PLAYWRIGHT_JUNIT_OUTPUT_DIR='/app/test-results' PLAYWRIGHT_JUNIT_OUTPUT_NAME='junit_results.xml' npx --prefix $PLAYWRIGHT_PATH playwright merge-reports --config=$PLAYWRIGHT_PATH/playwright.config.ts ./playwright-reports
|
||||||
"
|
"
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue