Esempio n. 1
0
 def test_getHalfExtentsWithoutMargin(self):
     """
     L{CylinderShape.getHalfExtentsWithoutMargin} returns the cylinder's half
     extents vector.
     """
     halfExtents = Vector3(2, 5, 7)
     shape = CylinderShape(halfExtents)
     result = shape.getHalfExtentsWithoutMargin()
     self.assertEqual(result.x, 1.9600000381469727)
     self.assertEqual(result.y, 4.9600000381469727)
     self.assertEqual(result.z, 6.9600000381469727)
Esempio n. 2
0
 def test_getHalfExtentsWithoutMargin(self):
     """
     L{CylinderShape.getHalfExtentsWithoutMargin} returns the cylinder's half
     extents vector.
     """
     halfExtents = Vector3(2, 5, 7)
     shape = CylinderShape(halfExtents)
     result = shape.getHalfExtentsWithoutMargin()
     self.assertEqual(result.x, 1.9600000381469727)
     self.assertEqual(result.y, 4.9600000381469727)
     self.assertEqual(result.z, 6.9600000381469727)
Esempio n. 3
0
 def test_radius(self):
     """
     L{CylinderShape.getRadius} returns the radius of the cylinder.
     """
     shape = CylinderShape(Vector3(1, 2, 3))
     self.assertEqual(shape.getRadius(), 1)
Esempio n. 4
0
 def test_instantiate(self):
     shape = CylinderShape(Vector3(1, 2, 3))
     self.assertTrue(isinstance(shape, CylinderShape))
Esempio n. 5
0
 def test_radius(self):
     """
     L{CylinderShape.getRadius} returns the radius of the cylinder.
     """
     shape = CylinderShape(Vector3(1, 2, 3))
     self.assertEqual(shape.getRadius(), 1)