summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesus Rivero <neurogeek@gentoo.org>2009-07-25 16:13:11 +0000
committerJesus Rivero <neurogeek@gentoo.org>2009-07-25 16:13:11 +0000
commite74cf6c7c39705fc75deeb0a7a800e45eb4dfa76 (patch)
tree5bd5a4a1bfd5f986ce7ce93d10f8c3637586a911 /dev-python/utidylib
parentVersion bump. Remove old. (diff)
downloadgentoo-2-e74cf6c7c39705fc75deeb0a7a800e45eb4dfa76.tar.gz
gentoo-2-e74cf6c7c39705fc75deeb0a7a800e45eb4dfa76.tar.bz2
gentoo-2-e74cf6c7c39705fc75deeb0a7a800e45eb4dfa76.zip
Revision bump. Fixed tests. Closes bug #276881
(Portage version: 2.2_rc23/cvs/Linux i686)
Diffstat (limited to 'dev-python/utidylib')
-rw-r--r--dev-python/utidylib/ChangeLog11
-rw-r--r--dev-python/utidylib/files/utidylib-0.2-fix_tests.patch33
-rw-r--r--dev-python/utidylib/files/utidylib-0.2-tests-twisted-2.1-compat.patch11
-rw-r--r--dev-python/utidylib/utidylib-0.2-r1.ebuild (renamed from dev-python/utidylib/utidylib-0.2.ebuild)16
4 files changed, 42 insertions, 29 deletions
diff --git a/dev-python/utidylib/ChangeLog b/dev-python/utidylib/ChangeLog
index 563155f0cfb1..86e1ddd6b990 100644
--- a/dev-python/utidylib/ChangeLog
+++ b/dev-python/utidylib/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-python/utidylib
-# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/utidylib/ChangeLog,v 1.7 2008/05/02 18:41:01 pythonhead Exp $
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-python/utidylib/ChangeLog,v 1.8 2009/07/25 16:13:11 neurogeek Exp $
+
+*utidylib-0.2-r1 (25 Jul 2009)
+
+ 25 Jul 2009; Jesus Rivero <neurogeek@gentoo.org> -utidylib-0.2.ebuild,
+ +utidylib-0.2-r1.ebuild, files/utidylib-0.2-fix_tests.patch,
+ -files/utidylib-0.2-tests-twisted-2.1-compat.patch:
+ Revision bump. Fixed tests. Closes bug #276881
02 May 2008; Rob Cakebread <pythonhead@gentoo.org> utidylib-0.2.ebuild:
Use berlios mirror. bug #218657
diff --git a/dev-python/utidylib/files/utidylib-0.2-fix_tests.patch b/dev-python/utidylib/files/utidylib-0.2-fix_tests.patch
index 319430134910..b55a15119ba4 100644
--- a/dev-python/utidylib/files/utidylib-0.2-fix_tests.patch
+++ b/dev-python/utidylib/files/utidylib-0.2-fix_tests.patch
@@ -1,17 +1,34 @@
---- tidy/test_tidy.py.orig 2007-01-06 21:43:08.000000000 +0100
-+++ tidy/test_tidy.py 2007-01-06 21:43:27.000000000 +0100
-@@ -20,8 +20,8 @@
+diff -uNr uTidylib-0.2.orig/tidy/test_tidy.py uTidylib-0.2/tidy/test_tidy.py
+--- uTidylib-0.2.orig/tidy/test_tidy.py 2004-02-24 08:53:52.000000000 +0000
++++ uTidylib-0.2/tidy/test_tidy.py 2009-07-25 15:50:56.000000000 +0000
+@@ -4,6 +4,10 @@
+
+ class TidyTestCase(unittest.TestCase):
+ def __init__(self, *args, **kwargs):
++ super(unittest.TestCase, self).__init__(*args, **kwargs)
++ self._shared = False
++ self._parents = []
++
+ foo = u'''<html>
+ <h1>woot</h1>
+ <hr>
+@@ -13,13 +17,13 @@
+ </body>
+ </html>
+ '''.encode('utf8')
+- file('foo.htm', 'w').write(foo)
++ file('foo.htm', 'w').write(foo)
+ self.input1 = "<html><script>1>2</script>"
+ self.input2 = "<html>\n" + "<p>asdkfjhasldkfjhsldjas\n" * 100
def defaultDocs(self):
doc1 = tidy.parseString(self.input1)
doc2 = tidy.parseString(self.input2)
- doc3 = tidy.parse("foo.htm")
-- doc4 = tidy.parse("bar.htm") # doesn't exist
+ doc3 = tidy.parse("../foo.htm")
-+ doc4 = tidy.parse("../bar.htm") # doesn't exist
+ doc4 = tidy.parse("bar.htm") # doesn't exist
return (doc1, doc2, doc3, doc4)
def test_badOptions(self):
- badopts = [{'foo': 1}, {'indent': '---'}, {'indent_spaces': None}]
-@@ -34,7 +34,7 @@
+@@ -33,7 +37,7 @@
self.fail("Invalid option %s should have raised an error" %
repr(dct))
def test_encodings(self):
@@ -20,7 +37,7 @@
'xmlcharrefreplace')
doc1u = tidy.parseString(foo, input_encoding='ascii',
output_encoding='latin1')
-@@ -59,7 +59,7 @@
+@@ -58,7 +62,7 @@
## self.failIf(len(doc2.errors)>1) # FIXME - tidylib doesn't
## # support this?
self.failUnless(str(doc2).find('\n')<0)
diff --git a/dev-python/utidylib/files/utidylib-0.2-tests-twisted-2.1-compat.patch b/dev-python/utidylib/files/utidylib-0.2-tests-twisted-2.1-compat.patch
deleted file mode 100644
index 0ee55e6d5631..000000000000
--- a/dev-python/utidylib/files/utidylib-0.2-tests-twisted-2.1-compat.patch
+++ /dev/null
@@ -1,11 +0,0 @@
-diff -ur uTidylib-0.2-orig/tidy/test_tidy.py uTidylib-0.2/tidy/test_tidy.py
---- uTidylib-0.2-orig/tidy/test_tidy.py 2005-12-01 00:48:14.000000000 +0100
-+++ uTidylib-0.2/tidy/test_tidy.py 2005-12-01 00:48:40.000000000 +0100
-@@ -4,6 +4,7 @@
-
- class TidyTestCase(unittest.TestCase):
- def __init__(self, *args, **kwargs):
-+ unittest.TestCase.__init__(self, *args, **kwargs)
- foo = u'''<html>
- <h1>woot</h1>
- <hr>
diff --git a/dev-python/utidylib/utidylib-0.2.ebuild b/dev-python/utidylib/utidylib-0.2-r1.ebuild
index 9f164be9bcb4..2fa98c202f24 100644
--- a/dev-python/utidylib/utidylib-0.2.ebuild
+++ b/dev-python/utidylib/utidylib-0.2-r1.ebuild
@@ -1,8 +1,9 @@
-# Copyright 1999-2008 Gentoo Foundation
+# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/utidylib/utidylib-0.2.ebuild,v 1.7 2008/05/02 18:41:01 pythonhead Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-python/utidylib/utidylib-0.2-r1.ebuild,v 1.1 2009/07/25 16:13:11 neurogeek Exp $
-inherit distutils eutils
+EAPI="2"
+inherit distutils
MY_P="uTidylib-${PV}"
@@ -26,10 +27,7 @@ DEPEND="${RDEPEND}
PYTHON_MODNAME="tidy"
S="${WORKDIR}/${MY_P}"
-src_unpack() {
- unpack ${A}
- cd "${S}"
- epatch "${FILESDIR}/${P}-tests-twisted-2.1-compat.patch"
+src_prepare(){
epatch "${FILESDIR}/${P}-no-docs-in-site-packages.patch"
epatch "${FILESDIR}/${P}-fix_tests.patch"
}
@@ -42,7 +40,9 @@ src_compile() {
}
src_test() {
- trial tidy || die "tests failed"
+ einfo "${S}"
+ einfo "$(ls ${S}/foo.htm)"
+ PYTHONPATH="." trial tidy || die "tests failed"
}
src_install() {