public void PlatformToSystemException(float x, float y) { #if __IOS__ var platform = new CoreGraphics.CGPoint(x, y); Assert.Throws <ArgumentOutOfRangeException>(() => platform.ToSystemPoint()); #elif WINDOWS_UWP var platform = new Windows.Foundation.Point(x, y); Assert.Throws <ArgumentOutOfRangeException>(() => platform.ToSystemPoint()); #endif }
public void PlatformToSystem() { #if __IOS__ var platform = new CoreGraphics.CGPoint(x, y); #elif __ANDROID__ var platform = new Android.Graphics.Point(x, y); #else var platform = new Windows.Foundation.Point(x, y); #endif var system = platform.ToSystemPoint(); Assert.Equal(x, system.X); Assert.Equal(y, system.Y); }