@@ -468,7 +468,7 @@ def testLoft(self):
468
468
self .assertEqual (7 , s .faces ().size ())
469
469
470
470
# test loft with combine="cut"
471
- box = Workplane ().box (10 , 10 , 10 ). solids ()
471
+ box = Workplane ().box (10 , 10 , 10 )
472
472
cut = (
473
473
box .faces (">Z" )
474
474
.workplane ()
@@ -480,6 +480,19 @@ def testLoft(self):
480
480
481
481
self .assertGreater (box .val ().Volume (), cut .val ().Volume ())
482
482
483
+ # test loft with combine=True
484
+ box = Workplane ().box (10 , 10 , 10 )
485
+ add = (
486
+ box .faces (">Z" )
487
+ .workplane ()
488
+ .circle (2 )
489
+ .workplane (offset = 12 )
490
+ .rect (3 , 2 )
491
+ .loft (combine = True )
492
+ )
493
+
494
+ self .assertGreater (add .val ().Volume (),box .val ().Volume ())
495
+
483
496
def testLoftRaisesValueError (self ):
484
497
s0 = Workplane ().hLine (1 ) # no wires
485
498
with raises (ValueError ):
@@ -1166,6 +1179,17 @@ def testSweep(self):
1166
1179
)
1167
1180
self .assertGreater (box .val ().Volume (), cut .val ().Volume ())
1168
1181
1182
+ #test sweep with combine = True
1183
+ box = Workplane ().box (10 , 10 , 10 , centered = False )
1184
+ path = Workplane ("YZ" ).lineTo (10 , 10 )
1185
+ add = (
1186
+ box .vertices (">Z and >X and >Y" )
1187
+ .workplane (centerOption = "CenterOfMass" )
1188
+ .circle (1.5 )
1189
+ .sweep (path , combine = True )
1190
+ )
1191
+ self .assertGreater (add .val ().Volume (),box .val ().Volume ())
1192
+
1169
1193
def testMultisectionSweep (self ):
1170
1194
"""
1171
1195
Tests the operation of sweeping along a list of wire(s) along a path
0 commit comments