Skip to content

Add Swift SDK generation and release checks #392

Add Swift SDK generation and release checks

Add Swift SDK generation and release checks #392

Workflow file for this run

name: Check submodules
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the main branch
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
check-submodules:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
persist-credentials: true
- name: Check all submodules up-to-date
env:
SWIFT_SUBMODULE_DEPLOY_KEY: ${{ secrets.SWIFT_SUBMODULE_DEPLOY_KEY }}
run: |
./scripts/checkout-submodules.bash --remote
git diff --exit-code
check-swagger:
runs-on: ubuntu-latest
needs: [check-submodules]
steps:
- uses: actions/checkout@v6
- name: Check existing swagger specification is up-to-date
run: curl https://api.aspose.cloud/v4.0/barcode/swagger/spec | diff --strip-trailing-cr -y --suppress-common-lines spec/aspose-barcode-cloud.json -
check-swift-codegen:
runs-on: macos-latest
steps:
- uses: actions/checkout@v6
- name: Checkout submodules
env:
SWIFT_SUBMODULE_DEPLOY_KEY: ${{ secrets.SWIFT_SUBMODULE_DEPLOY_KEY }}
run: ./scripts/checkout-submodules.bash
- uses: actions/setup-java@v5
with:
distribution: corretto
java-version: 21
- name: Show Swift version
run: swift --version
- name: Regenerate Swift SDK
run: make swift
- name: Check Swift SDK generation is reproducible
run: git diff --exit-code
- name: Run Swift tests
working-directory: submodules/swift
run: make test
- name: Run Swift live integration tests
working-directory: submodules/swift
run: make integration-test
env:
TEST_CONFIGURATION_ACCESS_TOKEN: ${{ secrets.TEST_CONFIGURATION_ACCESS_TOKEN }}