-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: api tests for CR pipeline (#9)
* feat: add base postman collection for tests * fix: postman collection * feat: postman collection for api tests * feat: add api tests for CR pipeline * feat: add api tests
- Loading branch information
1 parent
105cd80
commit 9480895
Showing
4 changed files
with
449 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
parameters: | ||
# Required | ||
- name: "ENV_FILE" | ||
type: string | ||
- name: "API_TEST_FILE" | ||
type: string | ||
- name: "TEST_FILE_PREFIX" | ||
type: string | ||
- name: 'TEST_DISPLAY_NAME' | ||
type: string | ||
steps: | ||
- script: | | ||
yarn global add newman | ||
displayName: 'Newman installation' | ||
- script: | | ||
newman run ${{ parameters.API_TEST_FILE }} -e ${{ parameters.ENV_FILE }} --ignore-redirects --reporters cli,junit --reporter-junit-export Results/${{ parameters.TEST_FILE_PREFIX }}-api-TEST.xml | ||
displayName: ${{ parameters.TEST_DISPLAY_NAME }} | ||
- task: PublishTestResults@2 | ||
condition: succeededOrFailed() | ||
inputs: | ||
testResultsFormat: 'JUnit' | ||
testResultsFiles: '**/${{ parameters.TEST_FILE_PREFIX }}-api-TEST.xml' | ||
searchFolder: '$(System.DefaultWorkingDirectory)' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"id": "5885a323-53a9-4090-b64d-758417ddc21c", | ||
"name": "user stats [LOCAL]", | ||
"values": [ | ||
{ | ||
"key": "HOSTNAME", | ||
"value": "http://localhost:8080", | ||
"type": "default", | ||
"enabled": true | ||
}, | ||
{ | ||
"key": "BASE_PATH", | ||
"value": "", | ||
"type": "default", | ||
"enabled": true | ||
}, | ||
{ | ||
"key": "USER_ID", | ||
"value": "00000000-0000-0000-0000-000000000000", | ||
"type": "default", | ||
"enabled": true | ||
}, | ||
{ | ||
"key": "GUEST_METHOD_LAST_USAGE_DATE", | ||
"value": "2000-01-01T12:00:00.123Z", | ||
"type": "any", | ||
"enabled": true | ||
}, | ||
{ | ||
"key": "WALLET_LAST_USAGE_DATE", | ||
"value": "2000-01-02T12:00:00.123Z", | ||
"type": "default", | ||
"enabled": true | ||
}, | ||
{ | ||
"key": "WALLET_ID", | ||
"value": "00000000-0000-0000-0000-000000000001", | ||
"type": "default", | ||
"enabled": true | ||
}, | ||
{ | ||
"key": "PAYMENT_METHOD_ID", | ||
"value": "00000000-0000-0000-0000-000000000002", | ||
"type": "default", | ||
"enabled": true | ||
} | ||
], | ||
"_postman_variable_scope": "environment", | ||
"_postman_exported_at": "2024-10-07T10:53:52.414Z", | ||
"_postman_exported_using": "Postman/11.15.0" | ||
} |
Oops, something went wrong.