You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Split Unity and C# tests into separate jobs (#3779)
# Description of Changes
<!-- Please describe your change, mention any related tickets, and so on
here. -->
This has 2 benefits:
1. If the Unity test fails because of a license issue then we don't have
to re-run the C# tests again as part of this flow. Re-running the Unity
tests will be much faster if that's the only thing the job is doing.
2. These tests will run faster because they will now run in parallel as
separate CI jobs.
# API and ABI breaking changes
<!-- If this is an API or ABI breaking change, please apply the
corresponding GitHub label. -->
None
# Expected complexity level and risk
1
<!--
How complicated do you think these changes are? Grade on a scale from 1
to 5,
where 1 is a trivial change, and 5 is a deep-reaching and complex
change.
This complexity rating applies not only to the complexity apparent in
the diff,
but also to its interactions with existing and future code.
If you answered more than a 2, explain what is complex about the PR,
and what other components it interacts with in potentially concerning
ways. -->
# Testing
<!-- Describe any testing you've done, and any testing you'd like your
reviewers to do,
so that you're confident that all the changes work as expected! -->
- [x] Both tests pass
---------
Signed-off-by: John Detter <4099508+jdetter@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Co-authored-by: Zeke Foppa <196249+bfops@users.noreply.github.com>
Co-authored-by: Zeke Foppa <bfops@users.noreply.github.com>
# Replace the com.clockworklabs.spacetimedbsdk dependency with the current branch.
626
+
# Note: Pointing to a local directory does not work, because our earlier steps nuke our meta files, which then causes Unity to not properly respect the DLLs (e.g.
627
+
# codegen does not work properly).
628
+
yq e -i '.dependencies["com.clockworklabs.spacetimedbsdk"] = "https://github.com/clockworklabs/SpacetimeDB.git?path=sdks/csharp#${{ github.head_ref }}"' manifest.json
629
+
cat manifest.json
630
+
631
+
- uses: actions/cache@v3
632
+
with:
633
+
path: demo/Blackholio/client-unity/Library
634
+
key: Unity-${{ github.head_ref }}
635
+
restore-keys: Unity-
636
+
637
+
# We need this to support "Docker in Docker"
638
+
- name: Start Docker daemon
639
+
run: /usr/local/bin/start-docker.sh
640
+
- name: Run Unity tests
641
+
uses: game-ci/unity-test-runner@v4
642
+
with:
643
+
unityVersion: 2022.3.32f1 # Adjust Unity version to a valid tag
644
+
projectPath: demo/Blackholio/client-unity # Path to the Unity project subdirectory
645
+
githubToken: ${{ secrets.GITHUB_TOKEN }}
646
+
testMode: playmode
647
+
useHostNetwork: true
648
+
artifactsPath: ""
649
+
env:
650
+
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
651
+
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
652
+
UNITY_SERIAL: ${{ secrets.UNITY_SERIAL }}
653
+
# Skip if this is an external contribution.
654
+
# The license secrets will be empty, so the step would fail anyway.
0 commit comments