-
Notifications
You must be signed in to change notification settings - Fork 3
ci: gate PRs on unit tests only and move integration to a daily run #91
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,117 @@ | ||
| name: _run-integration | ||
|
|
||
| on: | ||
| workflow_call: | ||
| secrets: | ||
| STREAM_API_SECRET: | ||
| required: true | ||
| STREAM_VIDEO_API_SECRET: | ||
| required: true | ||
| STREAM_GCP_API_SECRET: | ||
| required: false | ||
|
|
||
| concurrency: | ||
| # Repository-wide, on purpose. The contended resource is the Stream app, not the branch, | ||
| # so keying on github.ref would let a *.x release run beside the daily run on master. | ||
| # Not `github.workflow` either: inside a reusable workflow that resolves to the caller's | ||
| # name. Not cancel-in-progress: a half-run leaves users and channels behind. | ||
| group: run-integration | ||
| cancel-in-progress: false | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| integration-chat: | ||
| name: 🧪 Chat integration tests | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 30 | ||
| environment: ci | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Ruby | ||
| uses: ruby/setup-ruby@v1 | ||
| with: | ||
| ruby-version: '3.1.0' | ||
| bundler-cache: true | ||
|
|
||
| - name: Run chat integration tests | ||
| env: | ||
| STREAM_API_KEY: ${{ vars.STREAM_API_KEY }} | ||
| STREAM_API_SECRET: ${{ secrets.STREAM_API_SECRET }} | ||
| STREAM_BASE_URL: ${{ vars.STREAM_BASE_URL }} | ||
| run: make test-integration-chat | ||
|
|
||
| integration-feed: | ||
| name: 🧪 Feed integration tests | ||
| # Runs after chat rather than beside it: both blank and restore the app-global | ||
| # file_upload_config, so in parallel one suite's restore lands mid-assertion in | ||
| # the other. !cancelled() keeps the ordering without inheriting the implicit | ||
| # success(), so a red chat no longer hides whether feed passes. | ||
| needs: integration-chat | ||
| if: ${{ !cancelled() }} | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 30 | ||
| environment: ci | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Ruby | ||
| uses: ruby/setup-ruby@v1 | ||
| with: | ||
| ruby-version: '3.1.0' | ||
| bundler-cache: true | ||
|
|
||
| - name: Run feed integration tests | ||
| env: | ||
| STREAM_API_KEY: ${{ vars.STREAM_API_KEY }} | ||
| STREAM_API_SECRET: ${{ secrets.STREAM_API_SECRET }} | ||
| STREAM_BASE_URL: ${{ vars.STREAM_BASE_URL }} | ||
| run: make test-integration-feed | ||
|
|
||
| integration-video: | ||
| name: 🧪 Video integration tests | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 30 | ||
| environment: ci | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Ruby | ||
| uses: ruby/setup-ruby@v1 | ||
| with: | ||
| ruby-version: '3.1.0' | ||
| bundler-cache: true | ||
|
|
||
| - name: Run video integration tests | ||
| env: | ||
| STREAM_API_KEY: ${{ vars.STREAM_VIDEO_API_KEY }} | ||
| STREAM_API_SECRET: ${{ secrets.STREAM_VIDEO_API_SECRET }} | ||
| STREAM_BASE_URL: ${{ vars.STREAM_VIDEO_BASE_URL }} | ||
| run: make test-integration-video | ||
|
|
||
| integration-gcp-lb: | ||
| name: 🧪 GCP load balancer keep-alive | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 30 | ||
| environment: ci | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up Ruby | ||
| uses: ruby/setup-ruby@v1 | ||
| with: | ||
| ruby-version: '3.1.0' | ||
| bundler-cache: true | ||
|
|
||
| - name: Run GCP keep-alive integration test | ||
| env: | ||
| STREAM_API_KEY: ${{ vars.STREAM_GCP_API_KEY || vars.STREAM_API_KEY }} | ||
| STREAM_API_SECRET: ${{ secrets.STREAM_GCP_API_SECRET || secrets.STREAM_API_SECRET }} | ||
| STREAM_BASE_URL: ${{ vars.STREAM_GCP_BASE_URL }} | ||
| run: make test-integration-gcp-lb |
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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.