Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -198,3 +198,15 @@ jobs:
uses: ./.github/workflows/integration-test-windows.yml
with:
unreal-version: ${{ matrix.unreal }}

integration-test-android:
needs: [test-android]
name: Android UE ${{ matrix.unreal }}
secrets: inherit
strategy:
fail-fast: false
matrix:
unreal: ['5.4', '5.5', '5.6', '5.7']
uses: ./.github/workflows/integration-test-android.yml
with:
unreal-version: ${{ matrix.unreal }}
55 changes: 55 additions & 0 deletions .github/workflows/integration-test-android.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
on:
workflow_call:
inputs:
unreal-version:
required: true
type: string

jobs:
integration-test:
name: Integration Test
runs-on: ubuntu-latest

env:
SAUCE_USERNAME: ${{ secrets.SAUCE_USERNAME }}
SAUCE_ACCESS_KEY: ${{ secrets.SAUCE_ACCESS_KEY }}
GITHUB_TOKEN: ${{ github.token }}
SAUCE_REGION: eu-central-1

steps:
- uses: actions/checkout@v4
with:
submodules: recursive

- name: Download sample build
uses: actions/download-artifact@v4
with:
name: UE ${{ inputs.unreal-version }} sample build (Android)
path: sample-build

- name: Install Pester
shell: pwsh
run: Install-Module -Name Pester -Force -SkipPublisherCheck
Comment on lines +30 to +32
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pester: 5.7.1 is already installed in GH, have you had issues without this step?

https://github.com/actions/runner-images/blob/main/images/ubuntu/Ubuntu2404-Readme.md#powershell-modules


- name: Run integration tests
id: run-integration-tests
shell: pwsh
env:
SENTRY_UNREAL_TEST_DSN: ${{ secrets.SENTRY_UNREAL_TEST_DSN }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_API_TOKEN }}
SENTRY_UNREAL_TEST_APP_PATH: ${{ github.workspace }}/sample-build/SentryPlayground-arm64.apk
UNREAL_VERSION: ${{ inputs.unreal-version }}
run: |
cd integration-test
mkdir build
cmake -B build -S .
Invoke-Pester Integration.Tests.Android.SauceLabs.ps1 -CI
Comment on lines +34 to +46
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe a bit cleaner (move working dir to param and remove unnecessary mkdir)

Suggested change
- name: Run integration tests
id: run-integration-tests
shell: pwsh
env:
SENTRY_UNREAL_TEST_DSN: ${{ secrets.SENTRY_UNREAL_TEST_DSN }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_API_TOKEN }}
SENTRY_UNREAL_TEST_APP_PATH: ${{ github.workspace }}/sample-build/SentryPlayground-arm64.apk
UNREAL_VERSION: ${{ inputs.unreal-version }}
run: |
cd integration-test
mkdir build
cmake -B build -S .
Invoke-Pester Integration.Tests.Android.SauceLabs.ps1 -CI
- name: Run integration tests
id: run-integration-tests
shell: pwsh
working-directory: integration-test
env:
SENTRY_UNREAL_TEST_DSN: ${{ secrets.SENTRY_UNREAL_TEST_DSN }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_API_TOKEN }}
SENTRY_UNREAL_TEST_APP_PATH: ${{ github.workspace }}/sample-build/SentryPlayground-arm64.apk
UNREAL_VERSION: ${{ inputs.unreal-version }}
run: |
cmake -B build -S .
Invoke-Pester Integration.Tests.Android.SauceLabs.ps1 -CI

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, invoke-pester assumes files are named "*.Tests.ps1" so the filename should be Android.Adb.Tests.ps1 or similar. In this case it doesn't matter because you're specifying the exact path, but if you wanted to run all integration tests locally, calling invoke-pester integration-test would only pick up files ending with ".Tests.ps1"


- name: Upload integration test output
if: ${{ always() }}
uses: actions/upload-artifact@v4
with:
name: UE ${{ inputs.unreal-version }} integration test output (Android)
path: |
integration-test/output/
retention-days: 14
Loading