From 4e764977dc37604e202f8db4761417653e5bb4b2 Mon Sep 17 00:00:00 2001 From: Rolf Bjarne Kvinge Date: Thu, 27 Apr 2023 08:16:32 +0200 Subject: [PATCH] [tests] Allow a little bit of leeway when testing floating point numbers in SKTransformNodeTest. Fixes this test failure: MonoTouchFixtures.SpriteKit.SKTransformNodeTest [FAIL] EulerAngles : #x1 Expected: -2.14159298f But was: -2.14159274f --- tests/monotouch-test/SpriteKit/SKTransformNodeTest.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/monotouch-test/SpriteKit/SKTransformNodeTest.cs b/tests/monotouch-test/SpriteKit/SKTransformNodeTest.cs index ac8d4c65ff14..a0dd9c96c5fd 100644 --- a/tests/monotouch-test/SpriteKit/SKTransformNodeTest.cs +++ b/tests/monotouch-test/SpriteKit/SKTransformNodeTest.cs @@ -46,9 +46,9 @@ public void EulerAngles () V3 = new VectorFloat3 (1, 2, 3); obj.EulerAngles = V3; // The values bellow match what the same code in Swift returns. - Assert.AreEqual (-2.14159298f, obj.EulerAngles.X, "#x1"); - Assert.AreEqual (1.14159274f, obj.EulerAngles.Y, "#y1"); - Assert.AreEqual (-0.141592711f, obj.EulerAngles.Z, "#z1"); + Assert.AreEqual (-2.14159298f, obj.EulerAngles.X, 0.000001f, "#x1"); + Assert.AreEqual (1.14159274f, obj.EulerAngles.Y, 0.000001f, "#y1"); + Assert.AreEqual (-0.141592711f, obj.EulerAngles.Z, 0.000001f, "#z1"); } }