@ -70,13 +70,13 @@ namespace Avalonia.IntegrationTests.Appium
buttonMenuItem . MovePointerOver ( ) ;
buttonMenuItem . MovePointerOver ( ) ;
// Wait for tooltip to open.
// Wait for tooltip to open.
Thread . Sleep ( 1 0 0 0 ) ;
Thread . Sleep ( 2 0 0 0 ) ;
var toolTipCandidates = _ session . FindElementsByClassName ( "TextBlock" ) ;
var toolTipCandidates = _ session . FindElementsByClassName ( "TextBlock" ) ;
Assert . Contains ( toolTipCandidates , x = > x . Text = = "Button" ) ;
Assert . Contains ( toolTipCandidates , x = > x . Text = = "Tip: Button" ) ;
}
}
[PlatformFact(TestPlatforms.MacOS)]
[PlatformFact(TestPlatforms.MacOS, Skip = "Flaky test" )]
public void MacOS_Native_Menu_Has_ToolTip_If_Defined ( )
public void MacOS_Native_Menu_Has_ToolTip_If_Defined ( )
{
{
var menuBar = _ session . FindElementByXPath ( "/XCUIElementTypeApplication/XCUIElementTypeMenuBar" ) ;
var menuBar = _ session . FindElementByXPath ( "/XCUIElementTypeApplication/XCUIElementTypeMenuBar" ) ;
@ -87,10 +87,10 @@ namespace Avalonia.IntegrationTests.Appium
buttonMenuItem . MovePointerOver ( ) ;
buttonMenuItem . MovePointerOver ( ) ;
// Wait for tooltip to open.
// Wait for tooltip to open.
Thread . Sleep ( 2 0 0 0 ) ;
Thread . Sleep ( 4 0 0 0 ) ;
var toolTipCandidates = _ session . FindElementsByClassName ( "XCUIElementTypeStaticText" ) ;
var toolTipCandidates = _ session . FindElementsByClassName ( "XCUIElementTypeStaticText" ) ;
Assert . Contains ( toolTipCandidates , x = > x . Text = = "Button" ) ;
Assert . Contains ( toolTipCandidates , x = > x . Text = = "Tip: Button" ) ;
}
}
}
}
}
}