From ceb30381d435f5a6a96fe14bbfd90ef0dd1e013b Mon Sep 17 00:00:00 2001 From: "wu.shiming" Date: Thu, 4 Mar 2021 11:08:07 +0800 Subject: [PATCH] remove unicode from code In Python 3, all strings are represented in Unicode.In Python 2 are stored internally as 8-bit ASCII, hence it is required to attach 'u' to make it Unicode. It is no longer necessary now.' Change-Id: Ie3a439f0113423771bee7fb36b353df0ed68892e --- mistral/tests/unit/api/test_auth.py | 8 ++++---- mistral/tests/unit/engine/test_run_action.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/mistral/tests/unit/api/test_auth.py b/mistral/tests/unit/api/test_auth.py index ba29615d3..441410508 100644 --- a/mistral/tests/unit/api/test_auth.py +++ b/mistral/tests/unit/api/test_auth.py @@ -23,10 +23,10 @@ from mistral.tests.unit.api import base WORKBOOKS = [ { - u'name': u'my_workbook', - u'description': u'My cool Mistral workbook', - u'scope': None, - u'tags': [u'deployment', u'demo'] + 'name': 'my_workbook', + 'description': 'My cool Mistral workbook', + 'scope': None, + 'tags': ['deployment', 'demo'] } ] diff --git a/mistral/tests/unit/engine/test_run_action.py b/mistral/tests/unit/engine/test_run_action.py index b4d4f8289..bac19f23d 100644 --- a/mistral/tests/unit/engine/test_run_action.py +++ b/mistral/tests/unit/engine/test_run_action.py @@ -160,7 +160,7 @@ class RunActionEngineTest(base.EngineTestCase): action_ex = db_api.get_action_execution(action_ex.id) self.assertEqual(states.SUCCESS, action_ex.state) - self.assertEqual({'result': u'Hello, John Doe!'}, action_ex.output) + self.assertEqual({'result': 'Hello, John Doe!'}, action_ex.output) action_ex = self.engine.start_action( 'concat2',