aboutsummaryrefslogtreecommitdiffstats
path: root/tools/python/scripts
diff options
context:
space:
mode:
authorAlastair Tse <atse@xensource.com>2007-01-31 15:06:40 +0000
committerAlastair Tse <atse@xensource.com>2007-01-31 15:06:40 +0000
commitad643e3ef0104d2b986b7ce37fb8980bcb98d393 (patch)
tree9b21a6fb034d2ce6e91a64bec8ba8fc44c4c31ba /tools/python/scripts
parent48af590de3f0f1ca8113b9858d45bc6d44166d7c (diff)
downloadxen-ad643e3ef0104d2b986b7ce37fb8980bcb98d393.tar.gz
xen-ad643e3ef0104d2b986b7ce37fb8980bcb98d393.tar.bz2
xen-ad643e3ef0104d2b986b7ce37fb8980bcb98d393.zip
[XENAPI] Remove some deprecated fields from the Xen API test script.
Signed-off-by: Alastair Tse <atse@xensource.com>
Diffstat (limited to 'tools/python/scripts')
-rw-r--r--tools/python/scripts/test_hvm_create.py9
-rw-r--r--tools/python/scripts/test_vm_create.py11
2 files changed, 5 insertions, 15 deletions
diff --git a/tools/python/scripts/test_hvm_create.py b/tools/python/scripts/test_hvm_create.py
index 8effd42db9..7cae70539a 100644
--- a/tools/python/scripts/test_hvm_create.py
+++ b/tools/python/scripts/test_hvm_create.py
@@ -13,16 +13,11 @@ vm_cfg = {
'VCPUs_policy': 'credit',
- 'VCPUs_params': '',
+ 'VCPUs_params': {},
'VCPUs_number': 2,
- 'VCPUs_features_required': '',
- 'VCPUs_features_can_use': '',
- 'VCPUs_features_force_on': '',
- 'VCPUs_features_force_off': '',
'actions_after_shutdown': 'destroy',
'actions_after_reboot': 'restart',
- 'actions_after_suspend': 'destroy',
'actions_after_crash': 'destroy',
'PV_bootloader': '',
@@ -44,7 +39,7 @@ vm_cfg = {
local_vdi_cfg = {
'name_label': 'gentoo.hvm',
'name_description': '',
- 'uri': 'file:/root/gentoo.amd64.hvm.img',
+ 'location': 'file:/root/gentoo.amd64.hvm.img',
'virtual_size': 0,
'sector_size': 0,
'type': 'system',
diff --git a/tools/python/scripts/test_vm_create.py b/tools/python/scripts/test_vm_create.py
index 0d702aae69..84959c3e0d 100644
--- a/tools/python/scripts/test_vm_create.py
+++ b/tools/python/scripts/test_vm_create.py
@@ -15,14 +15,9 @@ vm_cfg = {
'VCPUs_policy': 'credit',
'VCPUs_params': '',
'VCPUs_number': 2,
- 'VCPUs_features_required': '',
- 'VCPUs_features_can_use': '',
- 'VCPUs_features_force_on': '',
- 'VCPUs_features_force_off': '',
'actions_after_shutdown': 'destroy',
'actions_after_reboot': 'restart',
- 'actions_after_suspend': 'destroy',
'actions_after_crash': 'destroy',
'PV_bootloader': '',
@@ -65,7 +60,7 @@ vbd_cfg = {
local_vdi_cfg = {
'name_label': 'gentoo.amd64.img',
'name_description': '',
- 'uri': 'file:/root/gentoo.amd64.img',
+ 'location': 'file:/root/gentoo.amd64.img',
'virtual_size': 0,
'sector_size': 0,
'type': 'system',
@@ -183,13 +178,13 @@ def test_vm_create():
execute(server, 'VM.resume', (session, vm_uuid, False))
print 'Resumed VM.'
+ finally:
# Wait for user to say we're good to shut it down
while True:
destroy = raw_input('destroy VM? ')
if destroy[0] in ('y', 'Y'):
break
-
- finally:
+
# Clean up
if vif_uuid:
execute(server, 'VIF.destroy', (session, vif_uuid))