Skip to content

Commit

Permalink
ci: Upadated postman workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
mike-pisman committed Oct 6, 2023
1 parent 2c29aac commit 598d729
Showing 1 changed file with 25 additions and 9 deletions.
34 changes: 25 additions & 9 deletions .github/workflows/postman.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,30 @@ jobs:
automated-api-tests:
runs-on: arc-runner-k8s
steps:
- uses: actions/checkout@v3
- name: Install Postman CLI
- uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install dependencies
run: |
curl -o- "https://dl-cli.pstmn.io/install/linux64.sh" | sh
- name: Login to Postman CLI
run: postman login --with-api-key ${{ secrets.POSTMAN_API_KEY }}
- name: Run API tests
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Get OpenAPI schema
run: |
postman collection run "${{ github.workspace }}/postman/collections/Automations: API-First Workflows.json" -e "19614303-61306d0f-9f72-418f-80ba-1561218563c9" --integration-id "129783-${{ github.run_id }}"
# Lint your API using Postman CLI
postman api lint --integration-id 129783
python main.py get-openapi
- uses: diegosanteri/publish-open-api-spec-to-postman@v1
with:
postmanApiKey: ${{ secrets.POSTMAN_API_KEY }}
postmanCollectionid: ${{ secrets.POSTMAN_COLLECTION_ID }}
swaggerPath: openapi.json
# - name: Install Postman CLI
# run: |
# curl -o- "https://dl-cli.pstmn.io/install/linux64.sh" | sh
# - name: Login to Postman CLI
# run: postman login --with-api-key ${{ secrets.POSTMAN_API_KEY }}
# - name: Run API tests
# run: |
# postman collection run "${{ github.workspace }}/postman/collections/Automations: API-First Workflows.json" -e "19614303-61306d0f-9f72-418f-80ba-1561218563c9" --integration-id "129783-${{ github.run_id }}"
# # Lint your API using Postman CLI
# postman api lint --integration-id 129783

0 comments on commit 598d729

Please sign in to comment.