Merge pull request #19 from ory/renovate/major-github-actions #73
This file contains hidden or 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
| name: Acceptance Tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| inputs: | |
| run_all: | |
| description: 'Run all tests' | |
| required: false | |
| default: true | |
| type: boolean | |
| enable_keto_tests: | |
| description: 'Keto/relationship tests' | |
| required: false | |
| default: false | |
| type: boolean | |
| enable_b2b_tests: | |
| description: 'B2B/organization tests' | |
| required: false | |
| default: false | |
| type: boolean | |
| enable_social_provider_tests: | |
| description: 'Social provider tests' | |
| required: false | |
| default: false | |
| type: boolean | |
| enable_schema_tests: | |
| description: 'Identity schema tests' | |
| required: false | |
| default: false | |
| type: boolean | |
| enable_project_tests: | |
| description: 'Project create/delete tests' | |
| required: false | |
| default: false | |
| type: boolean | |
| concurrency: | |
| group: acceptance-tests | |
| cancel-in-progress: false | |
| permissions: | |
| contents: read | |
| pull-requests: read | |
| jobs: | |
| detect-changes: | |
| name: Detect Changes | |
| runs-on: ubuntu-slim | |
| outputs: | |
| source-changed: ${{ steps.filter.outputs.source }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3 | |
| id: filter | |
| with: | |
| filters: | | |
| source: | |
| - '**.go' | |
| - 'go.mod' | |
| - 'go.sum' | |
| - '.github/workflows/acceptance-test.yml' | |
| acceptance-test: | |
| name: Build & Acceptance Test | |
| needs: detect-changes | |
| if: ${{ needs.detect-changes.outputs.source-changed == 'true' || github.event_name == 'workflow_dispatch' }} | |
| runs-on: ubuntu-slim | |
| timeout-minutes: 30 | |
| env: | |
| ORY_WORKSPACE_API_KEY: ${{ secrets.ORY_WORKSPACE_API_KEY }} | |
| ORY_WORKSPACE_ID: ${{ secrets.ORY_WORKSPACE_ID }} | |
| ORY_CONSOLE_API_URL: ${{ secrets.ORY_CONSOLE_API_URL }} | |
| ORY_PROJECT_API_URL: ${{ secrets.ORY_PROJECT_API_URL }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6 | |
| - name: Setup Go | |
| uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6 | |
| with: | |
| go-version-file: 'go.mod' | |
| cache: true | |
| - name: Install dependencies | |
| run: make deps-ci | |
| - name: Run Acceptance Tests | |
| env: | |
| ORY_KETO_TESTS_ENABLED: ${{ github.event_name == 'pull_request' || github.event.inputs.run_all == 'true' || github.event.inputs.enable_keto_tests == 'true' }} | |
| ORY_B2B_ENABLED: ${{ github.event_name == 'pull_request' || github.event.inputs.run_all == 'true' || github.event.inputs.enable_b2b_tests == 'true' }} | |
| ORY_SOCIAL_PROVIDER_TESTS_ENABLED: ${{ github.event_name == 'pull_request' || github.event.inputs.run_all == 'true' || github.event.inputs.enable_social_provider_tests == 'true' }} | |
| ORY_SCHEMA_TESTS_ENABLED: ${{ github.event_name == 'pull_request' || github.event.inputs.run_all == 'true' || github.event.inputs.enable_schema_tests == 'true' }} | |
| ORY_PROJECT_TESTS_ENABLED: ${{ github.event_name == 'pull_request' || github.event.inputs.run_all == 'true' || github.event.inputs.enable_project_tests == 'true' }} | |
| run: ./scripts/run-acceptance-tests.sh -v -timeout 20m ./... |