Skip to content

chore: Utilize app-runner for Android#2548

Merged
bitsandfoxes merged 31 commits intomainfrom
feat/app-runner-android
Feb 25, 2026
Merged

chore: Utilize app-runner for Android#2548
bitsandfoxes merged 31 commits intomainfrom
feat/app-runner-android

Conversation

@bitsandfoxes
Copy link
Contributor

@bitsandfoxes bitsandfoxes commented Feb 13, 2026

Goal

On Android, this moves the the Smoke Tests over to Integration Tests, utilizing app-runner to have actual end to end coverage.

Implementation

We only want to move the tests for Android specifically. To make use of the already existing infrastructure I introduced a TestLauncher that depending on the test case provided instantiates the correct MonoBehaviour. This has the side effect that the IntegrationTester also already compiles for all platforms, giving a positive signal, even tho it is not being used right now.

#skip-changelog

@github-actions
Copy link
Contributor

github-actions bot commented Feb 13, 2026

Semver Impact of This PR

🟢 Patch (bug fixes)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


This PR will not appear in the changelog.


🤖 This preview updates automatically when you update the PR.

Comment on lines +274 to +275
# api-level: [30, 31, 34]
api-level: [30]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll check and update the API levels in a followup.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We need a tiny bump on the .NET SDK here that hardcodes isAOT = false to fix some false positives on older Unity versions.

PlayerSettings.SetIl2CppCodeGeneration(NamedBuildTarget.FromBuildTargetGroup(group), UnityEditor.Build.Il2CppCodeGeneration.OptimizeSpeed);
#elif UNITY_2021_2_OR_NEWER
EditorUserBuildSettings.il2CppCodeGeneration = UnityEditor.Build.Il2CppCodeGeneration.OptimizeSize;
EditorUserBuildSettings.il2CppCodeGeneration = UnityEditor.Build.Il2CppCodeGeneration.OptimizeSpeed;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

A more likely setting for actual release builds.

Comment on lines -129 to -131
#if !UNITY_EDITOR
t.ExpectMessage(currentMessage, "'op':'awake','description':'Main Camera.SmokeTester'"); // auto instrumentation
#endif
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The current change from having a TestLauncher instead of having the MonoBehaviour already available during scene load makes this unfeasible. We can add this back in after the migration.

@bitsandfoxes bitsandfoxes requested a review from a team February 20, 2026 13:28
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We missed setting the Dist until now.

Comment on lines +53 to +58
if (args.TryGetValue("dsn", out value))
{
Debug.LogFormat("{0}: Setting DSN", functionName);
options.Dsn = value;
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We're overwriting the DSN now from CI to protect the project and for later test validation via Pester.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Extracted since these apply to all test cases, capture-event, capture-crash e.t.c.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is a temporary solution so we can use the old SmokeTester and the new IntegrationTester in parallel.

@bitsandfoxes bitsandfoxes merged commit 194aedd into main Feb 25, 2026
68 checks passed
@bitsandfoxes bitsandfoxes deleted the feat/app-runner-android branch February 25, 2026 13:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants