MCPcopy
hub / github.com/CadQuery/cadquery / testRotateAboutCenter

Method testRotateAboutCenter

tests/test_cadquery.py:323–328  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

321 self.assertEqual(2.5, startPoint[2])
322
323 def testRotateAboutCenter(self):
324 r = Workplane().box(1, 1, 1).rotateAboutCenter((1, 0, 0), 20)
325 assert len(r.edges("|X").vals()) == 4
326 assert r.faces(">X").vertices("<Y").val().Center().toTuple() == approx(
327 (0.5, -0.6408563820557885, 0.2988362387301199)
328 )
329
330 def testPlaneRotateZNormal(self):
331 """

Callers

nothing calls this directly

Calls 10

WorkplaneClass · 0.85
rotateAboutCenterMethod · 0.80
boxMethod · 0.80
valsMethod · 0.45
edgesMethod · 0.45
toTupleMethod · 0.45
CenterMethod · 0.45
valMethod · 0.45
verticesMethod · 0.45
facesMethod · 0.45

Tested by

no test coverage detected