Skip to content
Draft
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
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ public override void Configure(SentryUnityOptions options)
options.DisableAnrIntegration();
#pragma warning restore CS0618 // Type or member is obsolete

// App Hang tracking
options.EnableAppHangTracking = true;
// Only for the app hang test: on a slow device the 2s watchdog fires in the other tests too, and the hang event carries their tags.
options.EnableAppHangTracking = IntegrationTester.GetTestArg() == "app-hang-capture";
options.AppHangTimeout = TimeSpan.FromSeconds(2);

// Runtime initialization for integration tests
Expand Down
4 changes: 2 additions & 2 deletions test/Scripts.Integration.Test/Scripts/IntegrationTester.cs
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,9 @@ public void Start()
#if UNITY_IOS && !UNITY_EDITOR
// .NET `Environment.GetCommandLineArgs()` doesn't seem to work on iOS so we get the test arg in Objective-C
[DllImport("__Internal", EntryPoint="getTestArgObjectiveC")]
private static extern string GetTestArg();
internal static extern string GetTestArg();
#else
private static string GetTestArg()
internal static string GetTestArg()
{
string arg = null;
#if UNITY_EDITOR
Expand Down
Loading