diff options
author | Ryan Harper <ryan.harper@canonical.com> | 2018-05-17 11:57:37 -0400 |
---|---|---|
committer | Scott Moser <smoser@brickies.net> | 2018-05-17 11:57:37 -0400 |
commit | 2dab7046f88e540836498b363c90ad46302a7cc4 (patch) | |
tree | 45387011e06769cb0cd3132d3fa752164a259ac9 /tests/cloud_tests | |
parent | 13f7f4e802729d22e9906155fee435c3e8a8975b (diff) | |
download | vyos-cloud-init-2dab7046f88e540836498b363c90ad46302a7cc4.tar.gz vyos-cloud-init-2dab7046f88e540836498b363c90ad46302a7cc4.zip |
cloud_tests: help pylint
pylint missed finding a typo in the lxd platform because it could not
determine that the variable was being used was a string. The variable
was set by loading a yaml file which pylint couldn't know that it
would be a string. In these cases, we can be more explicit.
Diffstat (limited to 'tests/cloud_tests')
-rw-r--r-- | tests/cloud_tests/platforms/lxd/instance.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/cloud_tests/platforms/lxd/instance.py b/tests/cloud_tests/platforms/lxd/instance.py index 1c17c781..d396519f 100644 --- a/tests/cloud_tests/platforms/lxd/instance.py +++ b/tests/cloud_tests/platforms/lxd/instance.py @@ -208,7 +208,7 @@ def _has_proper_console_support(): if 'console' not in info.get('api_extensions', []): reason = "LXD server does not support console api extension" else: - dver = info.get('environment', {}).get('driver_version', "") + dver = str(info.get('environment', {}).get('driver_version', "")) if dver.startswith("2.") or dver.startswith("1."): reason = "LXD Driver version not 3.x+ (%s)" % dver else: |