Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Daniel Boeckenhoff
tfields
Commits
264219a8
Commit
264219a8
authored
May 14, 2020
by
dboe
Browse files
discovered mesh loading does not work with obj
parent
a4cc513e
Changes
2
Hide whitespace changes
Inline
Side-by-side
data/baffle.stl
deleted
100644 → 0
View file @
a4cc513e
File deleted
test/test_mesh3D.py
View file @
264219a8
from
tempfile
import
NamedTemporaryFile
import
tfields
import
numpy
as
np
import
unittest
...
...
@@ -22,6 +23,14 @@ class Mesh3D_Check(TensorMaps_Check):
# that is ok because self._inst could have stale indices etc..
self
.
assertTrue
(
tri
.
equal
(
tri_2
))
def
test_save_obj
(
self
):
out_file
=
NamedTemporaryFile
(
suffix
=
'.obj'
)
self
.
_inst
.
save
(
out_file
.
name
)
_
=
out_file
.
seek
(
0
)
# this is only necessary in the test
load_inst
=
type
(
self
.
_inst
).
load
(
out_file
.
name
)
print
(
self
.
_inst
,
load_inst
)
self
.
demand_equal
(
load_inst
)
class
Square_Test
(
Mesh3D_Check
,
unittest
.
TestCase
):
def
setUp
(
self
):
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment