public void Show_NSAction_Null() { TestRuntime.IgnoreOnMacCatalyst("https://github.com/xamarin/maccore/issues/2346"); // Once upon a time (circa 2012) using null for the action would have crashed the application // but it's not the case anymore (in 2015 / iOS9) and the header files says it's nullable GKNotificationBanner.Show("title", "message", null); }
public void NavigationControllerOverride() { TestRuntime.IgnoreOnTVOS(); // shouldAutorotate is not available on TVOS. TestRuntime.IgnoreOnMacCatalyst(); // rotation is not available on Mac Catalyst try { bool category_invoked = false; var vc = new UIViewController(); vc.View.BackgroundColor = UIColor.Yellow; var nc = new UINavigationController(vc); Rotation_IOS6.ShouldAutoRotateCallback = () => { category_invoked = true; vc.View.BackgroundColor = UIColor.Green; }; MonoTouchFixtures.AppDelegate.PresentModalViewController(nc, 0.5); Assert.That(category_invoked); } finally { Rotation_IOS6.ShouldAutoRotateCallback = null; } }