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

Function nested_assy_sphere

tests/test_assembly.py:84–96  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

82
83@pytest.fixture
84def nested_assy_sphere():
85
86 b1 = cq.Workplane().box(1, 1, 1).faces("<Z").tag("top_face").end()
87 b2 = cq.Workplane().box(1, 1, 1).faces("<Z").tag("bottom_face").end()
88 b3 = cq.Workplane().pushPoints([(-2, 0), (2, 0)]).tag("pts").sphere(1).tag("boxes")
89
90 assy = cq.Assembly(b1, loc=cq.Location(cq.Vector(0, 0, 0)), name="TOP")
91 assy2 = cq.Assembly(b2, loc=cq.Location(cq.Vector(0, 4, 0)), name="SECOND")
92 assy2.add(b3, loc=cq.Location(cq.Vector(0, 4, 0)), name="BOTTOM")
93
94 assy.add(assy2, color=cq.Color("green"))
95
96 return assy
97
98
99@pytest.fixture

Callers

nothing calls this directly

Calls 7

addMethod · 0.95
endMethod · 0.80
boxMethod · 0.80
sphereMethod · 0.80
pushPointsMethod · 0.80
tagMethod · 0.45
facesMethod · 0.45

Tested by

no test coverage detected