Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F63414299
test_py2ttl.py
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sun, May 19, 23:21
Size
681 B
Mime Type
text/x-python
Expires
Tue, May 21, 23:21 (2 d)
Engine
blob
Format
Raw Data
Handle
17770174
Attached To
rNIETZSCHEPYTHON nietzsche-python
test_py2ttl.py
View Options
import
unittest
from
os
import
sep
,
path
,
remove
import
lxml.etree
as
ET
import
lxml.html
import
py2ttl
from
datatypes.page
import
Page
class
TestConverter
(
unittest
.
TestCase
):
def
setUp
(
self
):
DATADIR
=
path
.
dirname
(
__file__
)
+
sep
+
'test_data'
self
.
test_file
=
DATADIR
+
sep
+
'test.xml'
self
.
test_svg_file
=
DATADIR
+
sep
+
'test421.svg'
self
.
outputfile_ttl
=
'test.ttl'
def
test_main
(
self
):
argv
=
[
'-t'
,
self
.
test_file
]
self
.
assertEqual
(
py2ttl
.
main
(
argv
),
0
)
def
tearDown
(
self
):
bool
(
path
.
isfile
(
self
.
outputfile_ttl
))
and
remove
(
self
.
outputfile_txt
)
if
__name__
==
"__main__"
:
unittest
.
main
()
Event Timeline
Log In to Comment