提交 bbd0da89 编写于 作者: M Martin Zikmund

fix: Ignore pointer injection tests for Uno Islands

上级 8ee0d673
......@@ -60,6 +60,8 @@ internal record UnitTestMethodInfo
public bool RunsOnUIThread { get; }
public bool UsesPointerInjection => _injectedPointerTypes.Count > 0;
private bool HasCustomAttribute<T>(MemberInfo? testMethod)
=> testMethod?.GetCustomAttribute(typeof(T)) != null;
......
......@@ -690,6 +690,8 @@ namespace Uno.UI.Samples.Tests
ReportTestClass(testClassInfo.Type.GetTypeInfo());
_ = ReportMessage($"Running {tests.Length} test methods");
var ignorePointerInjection = Private.Infrastructure.TestServices.WindowHelper.IsXamlIsland;
foreach (var test in tests)
{
var testName = test.Name;
......@@ -700,7 +702,8 @@ namespace Uno.UI.Samples.Tests
return;
}
if (test.IsIgnored(out var ignoreMessage))
if (test.IsIgnored(out var ignoreMessage) ||
(test.UsesPointerInjection && ignorePointerInjection))
{
if (config.IsRunningIgnored)
{
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册