forked from pool/python-lxml
update to 3.4.0 and add a patch that fixes test OBS-URL: https://build.opensuse.org/request/show/259611 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-lxml?expand=0&rev=78
30 lines
1.1 KiB
Diff
30 lines
1.1 KiB
Diff
From 720e43d6a0036ac12c438a5e5c1914d30d8603ff Mon Sep 17 00:00:00 2001
|
|
From: Stefan Behnel <stefan_ml@behnel.de>
|
|
Date: Sun, 19 Oct 2014 08:39:35 +0200
|
|
Subject: [PATCH] do not depend on formatting of "file:" URL in test (differs
|
|
across libxml2 versions)
|
|
|
|
---
|
|
src/lxml/tests/test_etree.py | 5 ++++-
|
|
1 file changed, 4 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/src/lxml/tests/test_etree.py b/src/lxml/tests/test_etree.py
|
|
index 1aa8cd7..6dafe04 100644
|
|
--- a/src/lxml/tests/test_etree.py
|
|
+++ b/src/lxml/tests/test_etree.py
|
|
@@ -1284,7 +1284,10 @@ class ETreeOnlyTestCase(HelperTestCase):
|
|
|
|
class MyResolver(self.etree.Resolver):
|
|
def resolve(self, url, id, context):
|
|
- assertEqual(url, fileUrlInTestDir(test_url))
|
|
+ expected = fileUrlInTestDir(test_url)
|
|
+ url = url.replace('file://', 'file:') # depends on libxml2 version
|
|
+ expected = expected.replace('file://', 'file:')
|
|
+ assertEqual(url, expected)
|
|
return self.resolve_filename(
|
|
fileUrlInTestDir('test.dtd'), context)
|
|
|
|
--
|
|
1.8.4.5
|
|
|