mirror of
https://github.com/qurator-spk/eynollah.git
synced 2025-06-30 14:39:54 +02:00
11 lines
360 B
Python
11 lines
360 B
Python
from lxml import etree as ET
|
|
from qurator.eynollah.utils.xml import create_page_xml, NAMESPACES
|
|
|
|
def tostring(el):
|
|
return ET.tostring(el).decode('utf-8')
|
|
|
|
def test_create_xml():
|
|
pcgts, page = create_page_xml('/path/to/img.tif', 100, 100)
|
|
xmlstr = tostring(pcgts)
|
|
assert 'xmlns="%s"' % NAMESPACES[None] in xmlstr
|
|
assert 'Metadata' in xmlstr
|