From 688e66c2b519c9095144f5dff767531fcb6fe38b Mon Sep 17 00:00:00 2001 From: ImmutableJeffrey Date: Mon, 11 May 2026 09:53:38 +1000 Subject: [PATCH 1/3] test(audience-sample): reset process-global test settings in TearDown (SDK-317) - Adds a TearDown to SampleAppLiveFireTests that resets the two process-globals SetUp mutates. - LogAssert.ignoreFailingMessages goes back to false so a later non-LiveFire fixture in the same test session does not inherit the permissive filter. - ServicePointManager.ServerCertificateValidationCallback goes back to null so the permissive cert validator does not leak to other code that runs in this process. Linear: SDK-317 Co-Authored-By: Claude Opus 4.7 (1M context) --- .../SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs b/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs index 9f6c59b9..84c05e7d 100644 --- a/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs +++ b/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs @@ -60,6 +60,13 @@ public void SetUp() _root = null; } + [TearDown] + public void TearDown() + { + LogAssert.ignoreFailingMessages = false; + System.Net.ServicePointManager.ServerCertificateValidationCallback = null; + } + // ---- Helpers shared by every test ---- // Loads the SampleApp scene, types the env-var key into publishable-key, From 8b543d8e629272bef368dbda9bf97278ea80fb3f Mon Sep 17 00:00:00 2001 From: ImmutableJeffrey Date: Mon, 11 May 2026 09:53:49 +1000 Subject: [PATCH 2/3] test(audience-sample): flush after the CI marker Track so the row actually ships (SDK-317) - AudienceCiTestMarker_EmitsRunMetadata calls Track but never flushes; the marker sits on the queue and the next test's SetUp deletes the persisted directory before it ever leaves the player. - Replaces the trailing yield-null with FlushAndAssertNoErrors so the marker is sent to the backend and any error rows fail the test. - Test now does what its name claims (emits the marker), not just "did not throw". Linear: SDK-317 Co-Authored-By: Claude Opus 4.7 (1M context) --- .../Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs b/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs index 84c05e7d..f68a8923 100644 --- a/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs +++ b/examples/audience/Assets/SampleApp/Tests/Runtime/SampleAppLiveFireTests.cs @@ -162,7 +162,7 @@ public IEnumerator AudienceCiTestMarker_EmitsRunMetadata() ["ciJobId"] = jobId ?? string.Empty, }); - yield return null; + yield return FlushAndAssertNoErrors("ci marker"); } [UnityTest] From 5938e50f0ab1b41d68f9ad0eb22b3db840110ab6 Mon Sep 17 00:00:00 2001 From: ImmutableJeffrey Date: Mon, 11 May 2026 09:54:11 +1000 Subject: [PATCH 3/3] ci(audience): write Unity activation log to /tmp so it stays out of CI artifacts (SDK-317) - The Linux PlayMode container script teed Unity license activation output to /github/workspace/artifacts/activation.log, and the workflow uploads everything under that directory as a downloadable artifact. - Unity's activation log can include sensitive account or entitlement details, so anyone with read access to the workflow run could pull them out of the artifact zip. - Moves ACTIVATION_LOG to /tmp/audience-unity-activation.log. The two grep checks that gate success / failure still read the same file, just from /tmp, and the file never reaches the artifact upload. Linear: SDK-317 Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/scripts/audience/playmode-linux-container.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/scripts/audience/playmode-linux-container.sh b/.github/scripts/audience/playmode-linux-container.sh index 991f73ee..09af39b9 100755 --- a/.github/scripts/audience/playmode-linux-container.sh +++ b/.github/scripts/audience/playmode-linux-container.sh @@ -6,7 +6,7 @@ set -uo pipefail LOG=/github/workspace/artifacts/unity.log -ACTIVATION_LOG=/github/workspace/artifacts/activation.log +ACTIVATION_LOG=/tmp/audience-unity-activation.log RESULTS=/github/workspace/artifacts/test-results.xml PROJECT=/github/workspace/examples/audience