rhtyd closed pull request #3061: Adding a try catch for Xen licensing issue
URL: https://github.com/apache/cloudstack/pull/3061
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git a/test/integration/smoke/test_scale_vm.py
b/test/integration/smoke/test_scale_vm.py
index e4d7b4029e1..ddd6bcfbc71 100644
--- a/test/integration/smoke/test_scale_vm.py
+++ b/test/integration/smoke/test_scale_vm.py
@@ -159,7 +159,14 @@ def test_01_scale_vm(self):
cmd = scaleVirtualMachine.scaleVirtualMachineCmd()
cmd.serviceofferingid = self.big_offering.id
cmd.id = self.virtual_machine.id
- self.apiclient.scaleVirtualMachine(cmd)
+
+ try:
+ self.apiclient.scaleVirtualMachine(cmd)
+ except Exception as e:
+ if "LicenceRestriction" in str(e):
+ self.skipTest("Your XenServer License does not allow scaling")
+ else:
+ self.fail("Scaling failed with the following exception: " +
str(e))
list_vm_response = VirtualMachine.list(
self.apiclient,
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services