poc/examples/coverage.poc
Jeff Epler db5b15bfc4 Major rewrite: switch from occmodel to pythonocc-core + vtk
.. this requires reverting to python2 due to lack of python3
vtk packages in debian stretch.

pythonocc-core is much more verbose, but it exposes the whole
oce API to Python, which means that I'm not stuck when I want
to expose something not in occmodel.  I hope that it's a better
way forward.
2017-08-11 21:35:32 -05:00

41 lines
852 B
Text

# This example isn't useful, except that it increases code coverage
with Union():
with Rotated(1, (0,0,1)):
Sphere((0,0,0), 6)
with Filleted(.5), Transformed(Matrix()), Chamfered(2):
Box((-5,-5,-5), (5,5,5))
print(Bbox())
print(CenterOfMass())
print(len(list(Faces())))
print(len(list(Vertices())))
print(len(list(Wires())))
Text(8, .25, 'Hello_world')
import poctools
poctools._dir(poctools._dir((1,2,3)))
poctools._vec(poctools._vec((1,2,3)))
poctools._pt(poctools._pt((1,2,3)))
poctools.Matrix(
(1,0,0),
(0,1,0),
(0,0,1))
poctools.Matrix(
(1,0,0,0),
(0,1,0,0),
(0,0,1,0))
poctools.Matrix(
1,0,0,0,
0,1,0,0,
0,0,1,0)
poctools.Matrix(
1,0,0,
0,1,0,
0,0,1)
poctools._dump(Object())
try:
poctools.do_op(None)
except ValueError:
pass
else:
1/0