Use string exception casting everywhere
Instead of the deprecated "message" member access,
casting to a string invokes the __str__ method of the exception
that is wired to return the message
Added a test of the failure cases of IpRouteCommand::delete_gateway
because they were missing
Running unit and functional tests locally no longer shows the warning
reported in the bug.
Change-Id: Ia79f526aa973ece1145615d65349f860aa3fd465
Closes-Bug: #1466542
diff --git a/neutron/tests/tempest/common/accounts.py b/neutron/tests/tempest/common/accounts.py
index 1fcef11..1a50e3c 100644
--- a/neutron/tests/tempest/common/accounts.py
+++ b/neutron/tests/tempest/common/accounts.py
@@ -271,7 +271,7 @@
return getattr(user, cred_arg) != getattr(alt_user, cred_arg)
except exceptions.InvalidCredentials as ic:
msg = "At least one of the configured credentials is " \
- "not valid: %s" % ic.message
+ "not valid: %s" % ic
raise exceptions.InvalidConfiguration(msg)
else:
# TODO(andreaf) Add a uniqueness check here