<86>May 2 11:30:38 userdel[128140]: delete user 'rooter' <86>May 2 11:30:38 userdel[128140]: removed group 'rooter' owned by 'rooter' <86>May 2 11:30:38 userdel[128140]: removed shadow group 'rooter' owned by 'rooter' <86>May 2 11:30:38 groupadd[128155]: group added to /etc/group: name=rooter, GID=630 <86>May 2 11:30:38 groupadd[128155]: group added to /etc/gshadow: name=rooter <86>May 2 11:30:38 groupadd[128155]: new group: name=rooter, GID=630 <86>May 2 11:30:38 useradd[128167]: new user: name=rooter, UID=630, GID=630, home=/root, shell=/bin/bash <86>May 2 11:30:38 userdel[128190]: delete user 'builder' <86>May 2 11:30:38 userdel[128190]: removed group 'builder' owned by 'builder' <86>May 2 11:30:38 userdel[128190]: removed shadow group 'builder' owned by 'builder' <86>May 2 11:30:38 groupadd[128207]: group added to /etc/group: name=builder, GID=631 <86>May 2 11:30:38 groupadd[128207]: group added to /etc/gshadow: name=builder <86>May 2 11:30:38 groupadd[128207]: new group: name=builder, GID=631 <86>May 2 11:30:38 useradd[128224]: new user: name=builder, UID=631, GID=631, home=/usr/src, shell=/bin/bash <13>May 2 11:30:43 rpmi: libgdbm-1.8.3-alt10 1454943334 installed <13>May 2 11:30:43 rpmi: libexpat-2.2.10-alt1 p9+261554.100.1.1 1605103337 installed <13>May 2 11:30:43 rpmi: libp11-kit-0.23.15-alt2 p9+254920.2400.19.1 1601385903 installed <13>May 2 11:30:43 rpmi: libtasn1-4.14-alt1 p9+235792.100.2.1 1565425233 installed <13>May 2 11:30:43 rpmi: rpm-macros-alternatives-0.5.1-alt1 sisyphus+226946.100.1.1 1554830426 installed <13>May 2 11:30:43 rpmi: alternatives-0.5.1-alt1 sisyphus+226946.100.1.1 1554830426 installed <13>May 2 11:30:43 rpmi: ca-certificates-2020.06.29-alt1 p9+258899.100.3.1 1601998604 installed <13>May 2 11:30:43 rpmi: ca-trust-0.1.2-alt1 p9+233349.100.1.1 1561655062 installed <13>May 2 11:30:43 rpmi: p11-kit-trust-0.23.15-alt2 p9+254920.2400.19.1 1601385903 installed <13>May 2 11:30:43 rpmi: libcrypto1.1-1.1.1k-alt1 p9+268376.100.3.1 1616721011 installed <13>May 2 11:30:43 rpmi: libssl1.1-1.1.1k-alt1 p9+268376.100.3.1 1616721011 installed <13>May 2 11:30:43 rpmi: python3-3.7.4-alt3 p9+249932.100.2.1 1587127349 installed <13>May 2 11:30:44 rpmi: libpython3-3.7.4-alt3 p9+249932.100.2.1 1587127349 installed <13>May 2 11:30:45 rpmi: python3-base-3.7.4-alt3 p9+249932.100.2.1 1587127349 installed <13>May 2 11:30:45 rpmi: tests-for-installed-python3-pkgs-0.1.13.1-alt2 1535450458 installed <13>May 2 11:30:45 rpmi: rpm-build-python3-0.1.13.1-alt2 1535450458 installed <13>May 2 11:30:52 rpmi: python3-module-pkg_resources-1:40.8.0-alt2 sisyphus+229158.200.2.1 1557735221 installed <13>May 2 11:30:52 rpmi: python-modules-curses-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:52 rpmi: libtinfo-devel-6.1.20180407-alt2 sisyphus+222164.200.1.1 1550686226 installed <13>May 2 11:30:52 rpmi: libncurses-devel-6.1.20180407-alt2 sisyphus+222164.200.1.1 1550686226 installed <13>May 2 11:30:52 rpmi: python3-dev-3.7.4-alt3 p9+249932.100.2.1 1587127349 installed <13>May 2 11:30:52 rpmi: libverto-0.3.0-alt1_7 sisyphus+225932.100.1.1 1553994919 installed <13>May 2 11:30:52 rpmi: libkeyutils-1.6-alt2 sisyphus+226520.100.2.1 1554512089 installed <13>May 2 11:30:52 rpmi: libcom_err-1.44.6-alt1 sisyphus+224154.100.1.1 1552091678 installed <86>May 2 11:30:52 groupadd[155813]: group added to /etc/group: name=_keytab, GID=499 <86>May 2 11:30:52 groupadd[155813]: new group: name=_keytab, GID=499 <13>May 2 11:30:52 rpmi: libkrb5-1.17.2-alt1 p9+262110.100.3.1 1606242416 installed <13>May 2 11:30:53 rpmi: libtirpc-1.0.3-alt1 1532008017 installed <13>May 2 11:30:53 rpmi: libnsl2-1.1.0-alt1_1 1511548749 installed <13>May 2 11:30:53 rpmi: python-modules-compiler-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-email-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-unittest-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-encodings-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-nis-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-ctypes-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-multiprocessing-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-logging-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-tools-2to3-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-xml-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-hotshot-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-bsddb-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-modules-distutils-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-module-pkg_resources-1:40.8.0-alt2 sisyphus+229158.200.2.1 1557735221 installed <13>May 2 11:30:53 rpmi: libnsl2-devel-1.1.0-alt1_1 1511548749 installed <13>May 2 11:30:53 rpmi: python-dev-2.7.16-alt1.M90P.2 p9+260393.40.3.1 1604003681 installed <13>May 2 11:30:53 rpmi: python-module-setuptools-1:40.8.0-alt2 sisyphus+229158.200.2.1 1557735221 installed <13>May 2 11:30:53 rpmi: python3-module-setuptools-1:40.8.0-alt2 sisyphus+229158.200.2.1 1557735221 installed Building target platforms: i586 Building for target i586 Wrote: /usr/src/in/nosrpm/python-module-zope.app.file-3.6.1-alt4.2.nosrc.rpm (w1.gzdio) Installing python-module-zope.app.file-3.6.1-alt4.2.src.rpm Building target platforms: i586 Building for target i586 Executing(%prep): /bin/sh -e /usr/src/tmp/rpm-tmp.91234 + umask 022 + /bin/mkdir -p /usr/src/RPM/BUILD + cd /usr/src/RPM/BUILD + cd /usr/src/RPM/BUILD + rm -rf python-module-zope.app.file-3.6.1 + echo 'Source #0 (python-module-zope.app.file-3.6.1.tar):' Source #0 (python-module-zope.app.file-3.6.1.tar): + /bin/tar -xf /usr/src/RPM/SOURCES/python-module-zope.app.file-3.6.1.tar + cd python-module-zope.app.file-3.6.1 + /bin/chmod -c -Rf u+rwX,go-w . + cp -fR . ../python3 + exit 0 Executing(%build): /bin/sh -e /usr/src/tmp/rpm-tmp.92285 + umask 022 + /bin/mkdir -p /usr/src/RPM/BUILD + cd /usr/src/RPM/BUILD + cd python-module-zope.app.file-3.6.1 + CFLAGS='-pipe -frecord-gcc-switches -Wall -g -O2 -march=i586 -mtune=generic' + export CFLAGS + CXXFLAGS='-pipe -frecord-gcc-switches -Wall -g -O2 -march=i586 -mtune=generic' + export CXXFLAGS + FFLAGS='-pipe -frecord-gcc-switches -Wall -g -O2 -march=i586 -mtune=generic' + export FFLAGS + /usr/bin/python setup.py build running build running build_py creating build creating build/lib creating build/lib/zope copying src/zope/__init__.py -> build/lib/zope creating build/lib/zope/app copying src/zope/app/__init__.py -> build/lib/zope/app creating build/lib/zope/app/file copying src/zope/app/file/testing.py -> build/lib/zope/app/file copying src/zope/app/file/interfaces.py -> build/lib/zope/app/file copying src/zope/app/file/image.py -> build/lib/zope/app/file copying src/zope/app/file/i18n.py -> build/lib/zope/app/file copying src/zope/app/file/file.py -> build/lib/zope/app/file copying src/zope/app/file/__init__.py -> build/lib/zope/app/file creating build/lib/zope/app/file/tests copying src/zope/app/file/tests/test_image.py -> build/lib/zope/app/file/tests copying src/zope/app/file/tests/test_functional_put.py -> build/lib/zope/app/file/tests copying src/zope/app/file/tests/test_file.py -> build/lib/zope/app/file/tests copying src/zope/app/file/tests/__init__.py -> build/lib/zope/app/file/tests creating build/lib/zope/app/file/browser copying src/zope/app/file/browser/image.py -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/file.py -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/__init__.py -> build/lib/zope/app/file/browser creating build/lib/zope/app/file/browser/tests copying src/zope/app/file/browser/tests/test_imagedata.py -> build/lib/zope/app/file/browser/tests copying src/zope/app/file/browser/tests/test_functional.py -> build/lib/zope/app/file/browser/tests copying src/zope/app/file/browser/tests/test_file.py -> build/lib/zope/app/file/browser/tests copying src/zope/app/file/browser/tests/__init__.py -> build/lib/zope/app/file/browser/tests running egg_info writing requirements to src/zope.app.file.egg-info/requires.txt writing src/zope.app.file.egg-info/PKG-INFO writing namespace_packages to src/zope.app.file.egg-info/namespace_packages.txt writing top-level names to src/zope.app.file.egg-info/top_level.txt writing dependency_links to src/zope.app.file.egg-info/dependency_links.txt reading manifest file 'src/zope.app.file.egg-info/SOURCES.txt' writing manifest file 'src/zope.app.file.egg-info/SOURCES.txt' copying src/zope/app/file/configure.zcml -> build/lib/zope/app/file copying src/zope/app/file/ftesting.zcml -> build/lib/zope/app/file copying src/zope/app/file/browser/configure.zcml -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/file.txt -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/file_add.pt -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/file_icon.gif -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/file_upload.pt -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/image_edit.pt -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/image_icon.gif -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/preview.pt -> build/lib/zope/app/file/browser copying src/zope/app/file/browser/url.txt -> build/lib/zope/app/file/browser + pushd ../python3 ~/RPM/BUILD/python3 ~/RPM/BUILD/python-module-zope.app.file-3.6.1 + find -type f -name '*.py' -exec 2to3 -w -n '{}' + RefactoringTool: Skipping optional fixer: buffer RefactoringTool: Skipping optional fixer: idioms RefactoringTool: Skipping optional fixer: set_literal RefactoringTool: Skipping optional fixer: ws_comma RefactoringTool: Refactored ./src/zope/app/file/tests/test_image.py RefactoringTool: Refactored ./src/zope/app/file/tests/test_functional_put.py --- ./src/zope/app/file/tests/test_image.py (original) +++ ./src/zope/app/file/tests/test_image.py (refactored) @@ -68,8 +68,8 @@ self.assertEqual(image.getImageSize(), (16, 16)) def testInterface(self): - self.failUnless(IImage.implementedBy(Image)) - self.failUnless(verifyClass(IImage, Image)) + self.assertTrue(IImage.implementedBy(Image)) + self.assertTrue(verifyClass(IImage, Image)) class TestFileAdapters(unittest.TestCase): @@ -109,50 +109,50 @@ def test_image(self): factory = FileFactory(None) f = factory("spam.txt", "image/foo", "hello world") - self.assert_(isinstance(f, Image), f) + self.assertTrue(isinstance(f, Image), f) f = factory("spam.txt", "", zptlogo) - self.assert_(isinstance(f, Image), f) + self.assertTrue(isinstance(f, Image), f) def test_text(self): factory = FileFactory(None) f = factory("spam.txt", "", "hello world") - self.assert_(isinstance(f, File), f) - self.assert_(not isinstance(f, Image), f) + self.assertTrue(isinstance(f, File), f) + self.assertTrue(not isinstance(f, Image), f) f = factory("spam.txt", "", "\0\1\2\3\4") - self.assert_(isinstance(f, File), f) - self.assert_(not isinstance(f, Image), f) + self.assertTrue(isinstance(f, File), f) + self.assertTrue(not isinstance(f, Image), f) f = factory("spam.txt", "text/splat", zptlogo) - self.assert_(isinstance(f, File), f) - self.assert_(not isinstance(f, Image), f) + self.assertTrue(isinstance(f, File), f) + self.assertTrue(not isinstance(f, Image), f) f = factory("spam.txt", "application/splat", zptlogo) - self.assert_(isinstance(f, File), f) - self.assert_(not isinstance(f, Image), f) + self.assertTrue(isinstance(f, File), f) + self.assertTrue(not isinstance(f, Image), f) class TestSized(unittest.TestCase): def testInterface(self): from zope.size.interfaces import ISized - self.failUnless(ISized.implementedBy(ImageSized)) - self.failUnless(verifyClass(ISized, ImageSized)) + self.assertTrue(ISized.implementedBy(ImageSized)) + self.assertTrue(verifyClass(ISized, ImageSized)) def test_zeroSized(self): s = ImageSized(DummyImage(0, 0, 0)) self.assertEqual(s.sizeForSorting(), ('byte', 0)) - self.assertEqual(s.sizeForDisplay(), u'0 KB ${width}x${height}') + self.assertEqual(s.sizeForDisplay(), '0 KB ${width}x${height}') self.assertEqual(s.sizeForDisplay().mapping['width'], '0') self.assertEqual(s.sizeForDisplay().mapping['height'], '0') def test_arbitrarySize(self): s = ImageSized(DummyImage(34, 56, 78)) self.assertEqual(s.sizeForSorting(), ('byte', 78)) - self.assertEqual(s.sizeForDisplay(), u'1 KB ${width}x${height}') + self.assertEqual(s.sizeForDisplay(), '1 KB ${width}x${height}') self.assertEqual(s.sizeForDisplay().mapping['width'], '34') self.assertEqual(s.sizeForDisplay().mapping['height'], '56') def test_unknownSize(self): s = ImageSized(DummyImage(-1, -1, 23)) self.assertEqual(s.sizeForSorting(), ('byte', 23)) - self.assertEqual(s.sizeForDisplay(), u'1 KB ${width}x${height}') + self.assertEqual(s.sizeForDisplay(), '1 KB ${width}x${height}') self.assertEqual(s.sizeForDisplay().mapping['width'], '?') self.assertEqual(s.sizeForDisplay().mapping['height'], '?') --- ./src/zope/app/file/tests/test_functional_put.py (original) +++ ./src/zope/app/file/tests/test_functional_put.py (refactored) @@ -34,13 +34,13 @@ This is just a test.""") - self.assertEquals(response.getStatus(), 201) - self.assertEquals(response.getHeader("Location"), + self.assertEqual(response.getStatus(), 201) + self.assertEqual(response.getHeader("Location"), "http://localhost/testfile.txt") response = http(r"""GET /testfRefactoringTool: No changes to ./src/zope/app/file/tests/test_file.py RefactoringTool: No changes to ./src/zope/app/file/testing.py RefactoringTool: Refactored ./src/zope/app/file/interfaces.py RefactoringTool: Refactored ./src/zope/app/file/image.py RefactoringTool: No changes to ./src/zope/app/file/i18n.py RefactoringTool: Refactored ./src/zope/app/file/file.py RefactoringTool: No changes to ./src/zope/app/file/browser/tests/test_imagedata.py RefactoringTool: Refactored ./src/zope/app/file/browser/tests/test_functional.py ile.txt HTTP/1.1 Authorization: Basic globalmgr:globalmgrpw""") - self.assertEquals(response.getBody(), "This is just a test.") + self.assertEqual(response.getBody(), "This is just a test.") # now modify it response = http(r"""PUT /testfile.txt HTTP/1.1 @@ -49,12 +49,12 @@ Content-Type: text/plain And now it is modified.""") - self.assertEquals(response.getStatus(), 200) - self.assertEquals(response.getBody(), "") + self.assertEqual(response.getStatus(), 200) + self.assertEqual(response.getBody(), "") response = http(r"""GET /testfile.txt HTTP/1.1 Authorization: Basic globalmgr:globalmgrpw""") - self.assertEquals(response.getBody(), "And now it is modified.") + self.assertEqual(response.getBody(), "And now it is modified.") def test_suite(): --- ./src/zope/app/file/interfaces.py (original) +++ ./src/zope/app/file/interfaces.py (refactored) @@ -25,16 +25,16 @@ class IFile(Interface): contentType = BytesLine( - title = _(u'Content Type'), - description=_(u'The content type identifies the type of data.'), + title = _('Content Type'), + description=_('The content type identifies the type of data.'), default='', required=False, missing_value='' ) data = Bytes( - title=_(u'Data'), - description=_(u'The actual content of the object.'), + title=_('Data'), + description=_('The actual content of the object.'), default='', missing_value='', required=False, --- ./src/zope/app/file/image.py (original) +++ ./src/zope/app/file/image.py (refactored) @@ -18,7 +18,7 @@ __docformat__ = 'restructuredtext' import struct -from cStringIO import StringIO +from io import StringIO from zope.interface import implements from zope.size.interfaces import ISized --- ./src/zope/app/file/file.py (original) +++ ./src/zope/app/file/file.py (refactored) @@ -131,7 +131,7 @@ def _setData(self, data) : # Handle case when data is a string - if isinstance(data, unicode): + if isinstance(data, str): data = data.encode('UTF-8') if isinstance(data, str): @@ -233,7 +233,7 @@ return len(data) def __str__(self): - next = self.next + next = self.__next__ if next is None: return self._data @@ -241,7 +241,7 @@ while next is not None: self = next result.append(self._data) - next = self.next + next = self.__next__ return ''.join(result) --- ./src/zope/app/file/browser/tests/test_functional.py (original) +++ ./src/zope/app/file/browser/tests/test_functional.py (refactored) @@ -19,7 +19,7 @@ import re import unittest from xml.sax.saxutils import escape -from StringIO import StringIO +from io import StringIO from zope.testing import renormalizing from zope.app.testing import functional @@ -32,7 +32,7 @@ class FileTest(BrowserTestCase): - content = u'File ' + content = 'File ' def addFile(self): file = File(self.content) @@ -46,28 +46,28 @@ basic='mgr:mgrpw') self.assertEqual(response.getStatus(), 200) body = response.getBody() - self.assert_('Add a File' in body) - self.assert_('Content Type' in body) - self.assert_('Data' in body) - self.assert_('Object Name' in body) - self.assert_('"Add"' in body) + self.assertTrue('Add a File' in body) + self.assertTrue('Content Type' in body) + self.assertTrue('Data' in body) + self.assertTrue('Object Name' in body) + self.assertTrue('"Add"' in body) self.checkForBrokenLinks(body, '/+/zope.app.file.File=', 'mgr:mgrpw') def testAdd(self): response = self.publish( '/+/zope.app.file.File=', - form={'type_name': u'zope.app.file.File', + form={'type_name': 'zope.app.file.File', 'field.data': StringIO('A file'), 'field.data.used': '', - 'add_input_name': u'file', - 'UPDATE_SUBMIT': u'Add'}, + 'add_input_name': 'file', + 'UPDATE_SUBMIT': 'Add'}, basic='mgr:mgrpw') self.assertEqual(response.getStatus(), 302) self.assertEqual(response.getHeader('Location'), 'http://localhost/@@contents.html') root = self.getRootFolder() - self.assert_('file' in root) + self.assertTrue('file' in root) file = root['file'] self.assertEqual(file.data, 'A file') @@ -76,16 +76,16 @@ data.filename="test.txt" response = self.publish( '/+/zope.app.file.File=', - form={'type_name': u'zope.app.file.File', + form={'type_name': 'zope.app.file.File', 'field.data': data, 'field.data.used': '', - 'UPDATE_SUBMIT': u'Add'}, + 'UPDATE_SUBMIT': 'Add'}, basic='mgr:mgrpw') self.assertEqual(response.getStatus(), 302) self.assertEqual(response.getHeader('Location'), 'http://localhost/@@contents.html') root = self.getRootFolder() - self.assert_('test.txt' in root) + self.assertTrue('test.txt' in root) file = root['test.txt'] self.assertEqual(file.data, 'File Contents') @@ -96,27 +96,27 @@ basic='mgr:mgrpw') self.assertEqual(response.getStatus(), 200) body = response.getBody() - self.assert_('Change a file' in body) - self.assert_('Content Type' in body) - self.assert_('Data' in body) - self.assert_(escape(self.content) in body) + self.assertTrue('Change a file' in body) + self.assertTrue('Content Type' in body) + self.assertTrue('Data' in body) + self.assertTrue(escape(self.content) in body) self.checkForBrokenLinks(body, '/file/@@edit.html', 'mgr:mgrpw') def testEdit(self): self.addFile() response = self.publish( '/file/@@edit.html', - form={'field.data': u'

A File

', - 'field.data.used': '', - 'field.contentType': u'text/plain', - 'UPDATE_SUBMIT': u'Edit'}, - basic='mgr:mgrpw') - self.assertEqual(response.getStatus(), 200) - body = response.getBody() - self.assert_('Change a file' in body) - self.assert_('Content Type' in body) - self.assert_('Data' in body) - self.assert_(escape(u'

A File

') in body) + form={'field.data': '

A File

', + 'field.data.used': '', + 'field.contentType': 'text/plain', + 'UPDATE_SUBMIT': 'Edit'}, + basic='mgr:mgrpw') + self.assertEqual(response.getStatus(), 200) + body = response.getBody() + self.assertTrue('Change a file' in body) + self.assertTrue('Content Type' in body) + self.assertTrue('Data' in body) + self.assertTrue(escape('

A File

') in body) root = self.getRootFolder() file = root['file'] self.assertEqual(file.data, '

A File

') @@ -129,10 +129,10 @@ basic='mgr:mgrpw') self.assertEqual(response.getStatus(), 200) body = response.getBody() - self.assert_('Upload a file' in body) - self.assert_('Content Type' in body) - self.assert_('Data' in body) - self.failIf(escape(self.content) in body) + self.assertTrue('Upload a file' in body) + self.assertTrue('Content Type' in body) + self.assertTrue('Data' in body) + self.assertFalse(escape(self.content) in body) self.checkForBrokenLinks(body, '/file/@@upload.html', 'mgr:mgrpw') def testUpload(self): @@ -141,15 +141,15 @@ '/file/@@upload.html', form={'field.data': StringIO('

A file

'), 'field.data.used': '', - 'field.contentType': u'text/plain', - 'UPDATE_SUBMIT': u'Change'}, - basic='mgr:mgrpw') - self.assertEqual(response.getStatus(), 200) - body = response.getBody() - self.assert_('Upload a file' in body) - self.assert_('Content Type' in body) - self.assert_('Data' in body) - self.failIf(escape(u'

A File

') in body) + 'field.contentType': 'text/plain', + 'UPDATE_SUBMIT': 'Change'}, + basic='mgr:mgrpw') + self.assertEqual(response.getStatus(), 200) + body = response.getBody() + self.assertTrue('Upload a file' in body) + self.assertTrue('Content Type' in body) + self.assertTrue('Data' in body) + self.assertFalse(escape('

A File

') in body) root = self.getRootFolder() file = root['file'] self.assertEqual(file.data, '

A file

') @@ -172,7 +172,7 @@ basic='mgr:mgrpw') self.assertEqual(response.getStatus(), 200) body = response.getBody() - self.assert_('