gutterball-3/Gutterball 3/Library/PackageCache/com.unity.analytics@3.2.2/Tests/Editor/Unity.Analytics.StandardEvents/ScreenVisitTests.cs
SkunkStudios 1c033119df New Version 1.42
Moving cam replay.
Fixed the bugs.

New Version 1.42

Moving cam replay.
Fixed the bugs.

New Version 1.42

Moving cam replay,
Fixed the bugs.
2025-01-29 16:19:11 +07:00

43 lines
1.3 KiB
C#

using System;
using NUnit.Framework;
namespace UnityEngine.Analytics.Tests
{
public partial class AnalyticsEventTests
{
[Test]
public void ScreenVisit_ScreenNameStringTest(
[Values("test_screen", "", null)] string screenName
)
{
if (string.IsNullOrEmpty(screenName))
{
Assert.Throws<ArgumentException>(() => AnalyticsEvent.ScreenVisit(screenName));
}
else
{
Assert.DoesNotThrow(() => m_Result = AnalyticsEvent.ScreenVisit(screenName));
EvaluateAnalyticsResult(m_Result);
}
}
[Test]
public void ScreenVisit_ScreenNameEnumTest(
[Values(ScreenName.CrossPromo, ScreenName.IAPPromo, ScreenName.None)] ScreenName screenName
)
{
Assert.DoesNotThrow(() => m_Result = AnalyticsEvent.ScreenVisit(screenName));
EvaluateAnalyticsResult(m_Result);
}
[Test]
public void ScreenVisit_CustomDataTest()
{
var screenName = ScreenName.MainMenu;
Assert.DoesNotThrow(() => m_Result = AnalyticsEvent.ScreenVisit(screenName, m_CustomData));
EvaluateCustomData(m_CustomData);
EvaluateAnalyticsResult(m_Result);
}
}
}