Пример #1
0
 def test_constant_iterable(self):
     function = _autowrap_function3d([3, 4, 5.0])
     self.assertIsInstance(function, Constant3D,
                           "Autowrapped iterable is not a vector3d.Constant3D.")
Пример #2
0
 def test_python_function(self):
     function = _autowrap_function3d(lambda x, y: Vector3D(x, y, x + y))
     self.assertIsInstance(function, PythonFunction3D,
                           "Autowrapped function is not a vector3d.PythonFunction3D.")
Пример #3
0
 def test_constant_vector(self):
     function = _autowrap_function3d(Vector3D(3.0, 4.0, 5.0))
     self.assertIsInstance(function, Constant3D,
                           "Autowrapped Vector3D is not a vector3d.Constant3D.")