From 9e7448a049c5b2c234801d7d98a5995960d99532 Mon Sep 17 00:00:00 2001 From: Philip Bauer Date: Fri, 21 Sep 2018 13:38:09 +0200 Subject: [PATCH] fix test --- plone/app/discussion/tests/test_comment.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/plone/app/discussion/tests/test_comment.py b/plone/app/discussion/tests/test_comment.py index c757db0..b8fdade 100644 --- a/plone/app/discussion/tests/test_comment.py +++ b/plone/app/discussion/tests/test_comment.py @@ -12,6 +12,7 @@ from zope.component import getMultiAdapter import datetime import logging +import six import unittest @@ -172,10 +173,14 @@ class CommentTest(unittest.TestCase): comment1 = createObject('plone.Comment') comment1.text = u'Umlaute sind ä, ö und ü.' out = b'

Umlaute sind \xc3\xa4, \xc3\xb6 und \xc3\xbc.

' - self.assertEqual( - comment1.getText(), - out.decode('utf8') - ) + if six.PY2: + self.assertEqual( + comment1.getText(), + out) + else: + self.assertEqual( + comment1.getText(), + out.decode('utf8')) def test_getText_doesnt_link(self): comment1 = createObject('plone.Comment')