diff options
Diffstat (limited to 'sysutils/bamf/files/patch-tests_gtester2xunit.py')
-rw-r--r-- | sysutils/bamf/files/patch-tests_gtester2xunit.py | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/sysutils/bamf/files/patch-tests_gtester2xunit.py b/sysutils/bamf/files/patch-tests_gtester2xunit.py new file mode 100644 index 000000000000..585123a4e699 --- /dev/null +++ b/sysutils/bamf/files/patch-tests_gtester2xunit.py @@ -0,0 +1,27 @@ +--- tests/gtester2xunit.py.orig 2018-11-07 22:39:11 UTC ++++ tests/gtester2xunit.py +@@ -1,18 +1,17 @@ + #! /usr/bin/python + from argparse import ArgumentParser +-import libxslt +-import libxml2 + import sys + import os ++from lxml import etree + + XSL_TRANSFORM='/usr/share/gtester2xunit/gtester.xsl' + + def transform_file(input_filename, output_filename, xsl_file): +- gtester = libxml2.parseFile(xsl_file) +- style = libxslt.parseStylesheetDoc(gtester) +- doc = libxml2.parseFile(input_filename) +- result = style.applyStylesheet(doc, None) +- result.saveFormatFile(filename=output_filename, format=True) ++ gtester = etree.parse(xsl_file) ++ style = etree.XSLT(gtester) ++ doc = etree.parse(input_filename) ++ result = style(doc) ++ result.write(filename=output_filename, format=True) + + + def get_output_filename(input_filename): |