commit:     89b03da374e6308342ecd918e9a09e20ca915adc
Author:     Michael Mair-Keimberger <mmk <AT> levelnine <DOT> at>
AuthorDate: Sun Aug 13 13:35:05 2023 +0000
Commit:     Florian Schmaus <flow <AT> gentoo <DOT> org>
CommitDate: Sun Aug 13 15:47:59 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=89b03da3

app-text/xml2rfc: remove unused patch(es)

Signed-off-by: Michael Mair-Keimberger <mmk <AT> levelnine.at>
Closes: https://github.com/gentoo/gentoo/pull/32292
Signed-off-by: Florian Schmaus <flow <AT> gentoo.org>

 .../xml2rfc/files/xml2rfc-Remove-broken-test.patch | 79 ----------------------
 1 file changed, 79 deletions(-)

diff --git a/app-text/xml2rfc/files/xml2rfc-Remove-broken-test.patch 
b/app-text/xml2rfc/files/xml2rfc-Remove-broken-test.patch
deleted file mode 100644
index d7d027962c24..000000000000
--- a/app-text/xml2rfc/files/xml2rfc-Remove-broken-test.patch
+++ /dev/null
@@ -1,79 +0,0 @@
-From ed27e2983c27065bd88ac82cd26a5b9128544b45 Mon Sep 17 00:00:00 2001
-From: Florian Schmaus <[email protected]>
-Date: Fri, 28 Oct 2022 20:18:10 +0200
-Subject: [PATCH] Remove broken test
-
---- a/test.py
-+++ b/test.py
-@@ -466,71 +466,6 @@ class WriterRfcTest(WriterRootTest):
-         return self.status_test()
- 
- 
--class PdfWriterTests(unittest.TestCase):
--    elements_root = None
--    elements_pdfxml = None
--
--    @classmethod
--    def setUpClass(cls) -> None:
--        # Putting this in setUpClass() allows this module to be imported even 
if this
--        # procedure will fail. This improves some error messages and makes 
debugging
--        # a little bit easier. The setUpClass() method is run by unittest 
during init.
--        # This happens only once, avoiding repeated execution of slow 
operations.
--        def _pdfwriter(path):
--            """ Parse a minimal RFC tree and instantiate a writer """
--            parser = xml2rfc.XmlRfcParser(path, quiet=True, 
**options_for_xmlrfcparser)
--            xmlrfc = parser.parse()
--            writer = xml2rfc.writers.pdf.PdfWriter(xmlrfc, quiet=True, )
--            return writer
--
--        elements_writer = _pdfwriter('tests/input/elements.xml')
--        try:
--            elements_pdfdoc = elements_writer.pdf() # has side effects on 
.root
--        except Exception as e:
--            print(e)
--            raise
--        cls.pdf_writer = elements_writer
--        cls.elements_root   = elements_writer.root
--        cls.elements_pdfxml = xmldoc(None, bytes=elements_pdfdoc)
--
--    def setUp(self):
--        xml2rfc.log.quiet = True
--        self.pdfxml = copy.deepcopy(self.elements_pdfxml)
--        self.root = copy.deepcopy(self.elements_root)
--
--    def test_text_content(self):
--        def norm(t):
--            return re.sub(r'\s+', ' ', t).strip()
--        #
--        text = norm('\n'.join( p.text for p in 
self.pdfxml.xpath('.//Page/text') ))
--        for e in self.root.xpath('./middle//*'):
--            if e.text and e.text.strip() and e.tag not in 
xml2rfc.util.unicode.unicode_content_tags and not 
xml2rfc.util.unicode.is_svg(e):
--                t =  norm(e.text.split(None, 1)[0])
--                self.assertIn(t, text)
--
--    def test_included_fonts(self):
--        if xml2rfc.HAVE_WEASYPRINT and xml2rfc.HAVE_PANGO:
--            font_families = set([ f.text for f in 
self.pdfxml.xpath('.//FontFamily') ])
--            for script in self.root.get('scripts').split(','):
--                family = 
xml2rfc.util.fonts.get_noto_serif_family_for_script(script)
--                self.assertIn(family, font_families, 'Missing font match for 
%s' % script)
--
--    def test_flatten_unicode_spans(self):
--        input_html = '<body><p>f<span class="unicode">o</span>o<span 
class="unicode">ba</span>r</p></body>'
--        output_html = self.pdf_writer.flatten_unicode_spans(input_html)
--        self.assertEqual(output_html, '<body><p>foobar</p></body>')
--
--    def test_get_serif_fonts(self):
--        fonts = self.pdf_writer.get_serif_fonts()
--        for font in ['Noto Serif', 'Noto Sans Cherokee', 'Noto Serif CJK SC', 
'Noto Serif Hebrew']:
--            self.assertIn(font, fonts)
--
--    def test_get_mono_fonts(self):
--        fonts = self.pdf_writer.get_mono_fonts()
--        for font in ['Roboto Mono', 'Noto Sans Cherokee', 'Noto Serif CJK 
SC', 'Noto Serif Hebrew']:
--            self.assertIn(font, fonts)
--
--
- class HtmlWriterTest(unittest.TestCase):
-     '''HtmlWriter tests'''
- 

Reply via email to