[Python-modules-commits] [python-tidylib] 02/05: merge patched into master

Mattia Rizzolo mattia at debian.org
Tue Sep 13 08:36:55 UTC 2016


This is an automated email from the git hooks/post-receive script.

mattia pushed a commit to branch master
in repository python-tidylib.

commit 0209755bc9f58a6c72b8f31991fd08f13c91a220
Merge: a670fe7 ff454c0
Author: Mattia Rizzolo <mattia at debian.org>
Date:   Tue Sep 13 08:28:57 2016 +0000

    merge patched into master

 debian/.git-dpm                                    |  4 +-
 ...ke-the-tests-pass-with-tidylib-5-fixes-13.patch | 68 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 tests/test_docs.py                                 |  8 +--
 tests/test_fragments.py                            |  8 +--
 5 files changed, 79 insertions(+), 10 deletions(-)

diff --cc debian/.git-dpm
index 96719b4,0000000..ddd0e08
mode 100644,000000..100644
--- a/debian/.git-dpm
+++ b/debian/.git-dpm
@@@ -1,11 -1,0 +1,11 @@@
 +# see git-dpm(1) from git-dpm package
- dca25b5942b5e9770f12412cff3760ac67213d7a
- dca25b5942b5e9770f12412cff3760ac67213d7a
++ff454c0115a676fc3dfb0dad5c98d47c78121b8d
++ff454c0115a676fc3dfb0dad5c98d47c78121b8d
 +dca25b5942b5e9770f12412cff3760ac67213d7a
 +dca25b5942b5e9770f12412cff3760ac67213d7a
 +python-tidylib_0.2.4~dfsg.orig.tar.gz
 +ced7e193bb3809a932f55f764bfd0a050d2bd3a6
 +8932
 +debianTag="debian/%e%v"
 +patchedTag="patched/%e%v"
 +upstreamTag="upstream/%e%u"
diff --cc debian/patches/0001-Make-the-tests-pass-with-tidylib-5-fixes-13.patch
index 0000000,0000000..a3e9f91
new file mode 100644
--- /dev/null
+++ b/debian/patches/0001-Make-the-tests-pass-with-tidylib-5-fixes-13.patch
@@@ -1,0 -1,0 +1,68 @@@
++From ff454c0115a676fc3dfb0dad5c98d47c78121b8d Mon Sep 17 00:00:00 2001
++From: Dmitry Shachnev <mitya57 at gmail.com>
++Date: Sat, 27 Aug 2016 23:48:06 +0300
++Subject: Make the tests pass with tidylib 5, fixes #13
++
++---
++ tests/test_docs.py      | 8 ++++----
++ tests/test_fragments.py | 8 ++++----
++ 2 files changed, 8 insertions(+), 8 deletions(-)
++
++diff --git a/tests/test_docs.py b/tests/test_docs.py
++index 45ced58..428feea 100644
++--- a/tests/test_docs.py
+++++ b/tests/test_docs.py
++@@ -48,20 +48,20 @@ class TestDocs1(unittest.TestCase):
++ 
++     def test_alt_added_to_img(self):
++         h = "<img src='foo'>"
++-        expected = DOC % '''<img src='foo' alt="">'''
++-        doc, err = tidy_document(h)
+++        expected = DOC % '''<img src='foo' alt="bar">'''
+++        doc, err = tidy_document(h, {'alt-text': 'bar'})
++         self.assertEqual(doc, expected)
++ 
++     def test_entity_preserved_using_bytes(self):
++         h = b"é"
++         expected = (DOC % "é").encode('utf-8')
++-        doc, err = tidy_document(h)
+++        doc, err = tidy_document(h, {'preserve-entities': 1})
++         self.assertEqual(doc, expected)
++ 
++     def test_numeric_entities_using_bytes(self):
++         h = b"é"
++         expected = (DOC % "é").encode('utf-8')
++-        doc, err = tidy_document(h, {'numeric-entities': 1})
+++        doc, err = tidy_document(h, {'numeric-entities': 1, 'output-encoding': 'ascii'})
++         self.assertEqual(doc, expected)
++ 
++     def test_non_ascii_preserved(self):
++diff --git a/tests/test_fragments.py b/tests/test_fragments.py
++index dcc7a3a..c329e15 100644
++--- a/tests/test_fragments.py
+++++ b/tests/test_fragments.py
++@@ -36,20 +36,20 @@ class TestFrags1(unittest.TestCase):
++ 
++     def test_alt_added_to_img(self):
++         h = "<img src='foo'>"
++-        expected = '''<img src='foo' alt="">'''
++-        doc, err = tidy_fragment(h)
+++        expected = '''<img src='foo' alt="bar">'''
+++        doc, err = tidy_fragment(h, {'alt-text': 'bar'})
++         self.assertEqual(doc, expected)
++ 
++     def test_entity_preserved_using_bytes(self):
++         h = b"é"
++         expected = b"é"
++-        doc, err = tidy_fragment(h)
+++        doc, err = tidy_fragment(h, {'preserve-entities': 1})
++         self.assertEqual(doc, expected)
++ 
++     def test_numeric_entities_using_bytes(self):
++         h = b"é"
++         expected = b"é"
++-        doc, err = tidy_fragment(h, {'numeric-entities': 1})
+++        doc, err = tidy_fragment(h, {'numeric-entities': 1, 'output-encoding': 'ascii'})
++         self.assertEqual(doc, expected)
++ 
++     def test_non_ascii_preserved(self):
diff --cc debian/patches/series
index 0000000,0000000..a9ca0f6
new file mode 100644
--- /dev/null
+++ b/debian/patches/series
@@@ -1,0 -1,0 +1,1 @@@
++0001-Make-the-tests-pass-with-tidylib-5-fixes-13.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/python-tidylib.git



More information about the Python-modules-commits mailing list