@@ -1226,7 +1226,7 @@ def testCut(self):
12261226 resS = currentS .cut (toCut .val ())
12271227
12281228 self .assertEqual (10 , resS .faces ().size ())
1229-
1229+
12301230 with self .assertRaises (ValueError ):
12311231 currentS .cut (toCut .faces ().val ())
12321232
@@ -1247,13 +1247,13 @@ def testIntersect(self):
12471247
12481248 self .assertEqual (6 , resS .faces ().size ())
12491249 self .assertAlmostEqual (resS .val ().Volume (), 0.5 )
1250-
1251- b1 = Workplane ('XY' ).box (1 ,1 , 1 )
1252- b2 = Workplane ('XY' , origin = (0 ,0 , 0.5 )).box (1 ,1 , 1 )
1250+
1251+ b1 = Workplane ("XY" ).box (1 , 1 , 1 )
1252+ b2 = Workplane ("XY" , origin = (0 , 0 , 0.5 )).box (1 , 1 , 1 )
12531253 resS = b1 .intersect (b2 )
1254-
1254+
12551255 self .assertAlmostEqual (resS .val ().Volume (), 0.5 )
1256-
1256+
12571257 with self .assertRaises (ValueError ):
12581258 b1 .intersect (b2 .faces ().val ())
12591259
@@ -2048,7 +2048,7 @@ def testUnions(self):
20482048 resS = currentS .union (toUnion )
20492049
20502050 self .assertEqual (11 , resS .faces ().size ())
2051-
2051+
20522052 with self .assertRaises (ValueError ):
20532053 resS .union (toUnion .faces ().val ())
20542054
@@ -3376,14 +3376,16 @@ def testMakeHelix(self):
33763376
33773377 def testUnionCompound (self ):
33783378
3379- box1 = Workplane ('XY' ).box (10 , 20 , 30 )
3380- box2 = Workplane ('YZ' ).box (10 , 20 , 30 )
3381- shape_to_cut = Workplane ('XY' ).box (15 , 15 , 15 ).translate ((8 ,8 , 8 ))
3382-
3379+ box1 = Workplane ("XY" ).box (10 , 20 , 30 )
3380+ box2 = Workplane ("YZ" ).box (10 , 20 , 30 )
3381+ shape_to_cut = Workplane ("XY" ).box (15 , 15 , 15 ).translate ((8 , 8 , 8 ))
3382+
33833383 list_of_shapes = []
3384- for o in box1 .all (): list_of_shapes .extend (o .vals ())
3385- for o in box2 .all (): list_of_shapes .extend (o .vals ())
3386-
3387- obj = Workplane ('XY' ).newObject (list_of_shapes ).cut (shape_to_cut )
3388-
3389- assert (obj .val ().isValid ())
3384+ for o in box1 .all ():
3385+ list_of_shapes .extend (o .vals ())
3386+ for o in box2 .all ():
3387+ list_of_shapes .extend (o .vals ())
3388+
3389+ obj = Workplane ("XY" ).newObject (list_of_shapes ).cut (shape_to_cut )
3390+
3391+ assert obj .val ().isValid ()
0 commit comments