diff options
author | Stephen Finucane <sfinucan@redhat.com> | 2020-02-21 09:43:13 +0000 |
---|---|---|
committer | Stephen Finucane <sfinucan@redhat.com> | 2020-02-21 09:43:13 +0000 |
commit | 0f7d723c462ab0c083120f811fba682057f2b081 (patch) | |
tree | f48bdeb2fc490446de2bc74c8a8d7e6593d9878e | |
parent | eb98178ea88c77881f7c763b068408f769956eb2 (diff) | |
download | python-novaclient-0f7d723c462ab0c083120f811fba682057f2b081.tar.gz |
trivial: Remove 'u' prefix from string
It looks like nova is using 'repr()' in some validation error logging.
On Python 2.7, this would result in unicode strings (which most web apps
use) being output as "u'foo'", while in Python 3 these would just be
"'foo'". Since nova only supports Python 3 now, we only have to support
the Python 3 string formatting variant in our tests too.
Change-Id: I546c06a3251e86f39e2e7db48e04ec382c8da854
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
-rw-r--r-- | novaclient/tests/functional/v2/test_servers.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/novaclient/tests/functional/v2/test_servers.py b/novaclient/tests/functional/v2/test_servers.py index 030f0f27..a25dd2ae 100644 --- a/novaclient/tests/functional/v2/test_servers.py +++ b/novaclient/tests/functional/v2/test_servers.py @@ -130,7 +130,7 @@ class TestServersDescription(base.ClientTestBase): output = self.nova("update %s --description '%s'" % (server.id, descr), fail_ok=True, merge_stderr=True) self.assertIn("ERROR (BadRequest): Invalid input for field/attribute" - " description. Value: %s. u\'%s\' is too long (HTTP 400)" + " description. Value: %s. '%s' is too long (HTTP 400)" % (descr, descr), output) |