Skip to content

Commit 7e75f12

Browse files
author
Chris Elion
committed
fix unit tests
1 parent e3adeb6 commit 7e75f12

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

com.unity.ml-agents.extensions/Tests/Editor/Sensors/RigidBodyPoseExtractorTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public void TestTwoBodies()
6363
rb1.velocity = new Vector3(2, 0, 0);
6464

6565
Assert.AreEqual(rb1.position, poseExtractor.GetPoseAt(0).position);
66-
Assert.AreEqual(rb1.rotation, poseExtractor.GetPoseAt(0).rotation);
66+
Assert.IsTrue(rb1.rotation == poseExtractor.GetPoseAt(0).rotation);
6767
Assert.AreEqual(rb1.velocity, poseExtractor.GetLinearVelocityAt(0));
6868
}
6969

@@ -103,7 +103,7 @@ public void TestTwoBodiesVirtualRoot()
103103
virtualRoot.transform.rotation = virtualRootRot;
104104

105105
Assert.AreEqual(virtualRootPos, poseExtractor.GetPoseAt(0).position);
106-
Assert.AreEqual(virtualRootRot, poseExtractor.GetPoseAt(0).rotation);
106+
Assert.IsTrue(virtualRootRot == poseExtractor.GetPoseAt(0).rotation);
107107
Assert.AreEqual(Vector3.zero, poseExtractor.GetLinearVelocityAt(0));
108108

109109
// Same as above test, but using index 1
@@ -112,7 +112,7 @@ public void TestTwoBodiesVirtualRoot()
112112
rb1.velocity = new Vector3(2, 0, 0);
113113

114114
Assert.AreEqual(rb1.position, poseExtractor.GetPoseAt(1).position);
115-
Assert.AreEqual(rb1.rotation, poseExtractor.GetPoseAt(1).rotation);
115+
Assert.IsTrue(rb1.rotation == poseExtractor.GetPoseAt(1).rotation);
116116
Assert.AreEqual(rb1.velocity, poseExtractor.GetLinearVelocityAt(1));
117117
}
118118
}

0 commit comments

Comments
 (0)