Various fixes to tests

- Configuration fixes in Security groups and Egress rules
- Fixing white spaces in component test suite
This commit is contained in:
Prasanna Santhanam 2012-07-06 16:50:20 +05:30
parent a725fdc3ab
commit b433b1afa6
18 changed files with 1176 additions and 1113 deletions

View File

@ -57,8 +57,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"virtual_machine": {
"displayname": "Test VM",
@ -78,7 +78,7 @@ class Services:
"ostypeid": 'aaf6e8c9-b609-441d-9ebd-b4eaa030a275',
"url": "http://download.cloud.com/releases/2.0.0/UbuntuServer-10-04-64bit.vhd.bz2",
"hypervisor": 'XenServer',
"format" : 'VHD',
"format": 'VHD',
"isfeatured": True,
"ispublic": True,
"isextractable": True,
@ -87,7 +87,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode":'advanced'
"mode": 'advanced'
}
@ -372,6 +372,7 @@ class TestRemoveUserFromAccount(cloudstackTestCase):
"Check state of VMs associated with account"
)
return
@unittest.skip("Open Questions")
def test_02_remove_all_users(self):
"""Test Remove both users from the account
@ -695,6 +696,7 @@ class TestServiceOfferingSiblings(cloudstackTestCase):
)
return
@unittest.skip("Open Questions")
class TestServiceOfferingHierarchy(cloudstackTestCase):
@ -821,6 +823,7 @@ class TestServiceOfferingHierarchy(cloudstackTestCase):
)
return
@unittest.skip("Open Questions")
class TesttemplateHierarchy(cloudstackTestCase):
@ -959,6 +962,7 @@ class TesttemplateHierarchy(cloudstackTestCase):
)
return
class TestAddVmToSubDomain(cloudstackTestCase):
@classmethod
@ -1026,19 +1030,20 @@ class TestAddVmToSubDomain(cloudstackTestCase):
serviceofferingid=cls.service_offering.id
)
cls._cleanup = [
cls.account_2,
cls.account_1,
cls.sub_domain,
cls.service_offering
]
cls.account_2,
cls.account_1,
cls.sub_domain,
cls.service_offering
]
return
@classmethod
def tearDownClass(cls):
try:
#Clean up, terminate the created resources
cleanup_resources(cls.api_client,cls._cleanup)
except Exception as e:
cleanup_resources(cls.api_client, cls._cleanup)
except Exception as e:
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@ -1056,7 +1061,6 @@ class TestAddVmToSubDomain(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
def test_01_add_vm_to_subdomain(self):
""" Test Sub domain allowed to launch VM when a Domain level zone is
created"""

View File

@ -26,6 +26,7 @@ from marvin.cloudstackTestCase import *
from marvin.cloudstackAPI import *
from marvin.remoteSSHClient import remoteSSHClient
class Services:
"""Test Services
"""
@ -48,8 +49,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Small",
@ -69,7 +70,7 @@ class Services:
"volume": {
"diskname": "APP Data Volume",
"size": 1, # in GBs
"diskdevice": "/dev/xvdb", # Data Disk
"diskdevice": "/dev/xvdb", # Data Disk
},
"templates": {
"displaytext": 'Template from snapshot',
@ -78,11 +79,11 @@ class Services:
"templatefilter": 'self',
"url": "http://download.cloud.com/releases/2.0.0/UbuntuServer-10-04-64bit.vhd.bz2",
"hypervisor": 'XenServer',
"format" : 'VHD',
"format": 'VHD',
"isfeatured": True,
"ispublic": True,
"isextractable": True,
"passwordenabled":True,
"passwordenabled": True,
},
"paths": {
"mount_dir": "/mnt/tmp",
@ -98,7 +99,7 @@ class Services:
},
"ostypeid": '144f66aa-7f74-4cfe-9799-80cc21439cb3',
# Cent OS 5.3 (64 bit)
"sleep":60,
"sleep": 60,
"mode": 'advanced',
# Networking mode, Advanced, Basic
}
@ -312,7 +313,7 @@ class TestSnapshots(cloudstackTestCase):
None,
"Check Volume list Length"
)
self.assertEqual (
self.assertEqual(
volumes[0].id,
volume_from_snapshot.id,
"Check Volume in the List Volumes"
@ -524,7 +525,7 @@ class TestTemplate(cloudstackTestCase):
)
self.debug("Deployed VM with ID: %s " % virtual_machine.id)
self.assertEqual(
hasattr(virtual_machine,"password"),
hasattr(virtual_machine, "password"),
True,
"Check if the deployed VM returned a password"
)
@ -909,7 +910,6 @@ class TestRouterRestart(cloudstackTestCase):
self.apiclient = self.testClient.getApiClient()
return
def test_01_restart_network_cleanup(self):
"""TS_BUG_008-Test restart network
"""

View File

@ -37,7 +37,7 @@ class Services:
def __init__(self):
self.services = {
"disk_offering":{
"disk_offering": {
"displaytext": "Small",
"name": "Small",
"disksize": 1
@ -67,8 +67,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"security_group": {
"name": 'SSH',
@ -110,8 +110,9 @@ class Services:
"protocol": 'TCP',
"startport": 22,
"endport": 22,
"cidrlist": '0.0.0.0/0'
},
"mgmt_server": {
"mgmt_server": {
"username": "root",
"password": "fr3sca",
"ipaddress": "192.168.100.21"
@ -120,7 +121,7 @@ class Services:
# CentOS 5.3 (64-bit)
"sleep": 60,
"timeout": 10,
"mode":'basic',
"mode": 'basic',
# Networking mode: Basic or Advanced
}
@ -811,7 +812,7 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase):
# --- www.l.google.com ping statistics ---
# 1 packets transmitted, 1 received, 0% packet loss, time 0ms
# rtt min/avg/max/mdev = 25.970/25.970/25.970/0.000 ms
self.debug("SSH result: %s" % str(res))
self.debug("SSH result: %s" % str(res))
except Exception as e:
self.fail("SSH Access failed for %s: %s" % \
(self.virtual_machine.ipaddress, e)
@ -997,7 +998,7 @@ class TestRevokeEgressRule(cloudstackTestCase):
# --- www.l.google.com ping statistics ---
# 1 packets transmitted, 1 received, 0% packet loss, time 0ms
# rtt min/avg/max/mdev = 25.970/25.970/25.970/0.000 ms
self.debug("SSH result: %s" % str(res))
self.debug("SSH result: %s" % str(res))
except Exception as e:
self.fail("SSH Access failed for %s: %s" % \
(self.virtual_machine.ipaddress, e)
@ -1038,7 +1039,7 @@ class TestRevokeEgressRule(cloudstackTestCase):
result = security_group.revokeEgress(
self.apiclient,
id = ssh_egress_rule["ruleid"]
id=ssh_egress_rule["ruleid"]
)
self.debug("Revoke egress rule result: %s" % result)
@ -1335,14 +1336,14 @@ class TestMultipleAccountsEgressRuleNeg(cloudstackTestCase):
"Authorizing egress rule for sec group ID: %s for ssh access"
% security_group.id)
# Authorize to only account not CIDR
user_secgrp_list = {self.accountB.account.name: 'default'}
user_secgrp_list = {self.accountB.account.name: 'default'}
egress_rule = security_group.authorizeEgress(
self.apiclient,
self.services["sg_account"],
account=self.accountA.account.name,
domainid=self.accountA.account.domainid,
user_secgrp_list=user_secgrp_list
user_secgrp_list=user_secgrp_list
)
self.assertEqual(
@ -1438,7 +1439,7 @@ class TestMultipleAccountsEgressRuleNeg(cloudstackTestCase):
try:
self.debug("SSHing into VM type B from VM A")
self.debug("VM IP: %s" % self.virtual_machineB.ssh_ip)
self.debug("VM IP: %s" % self.virtual_machineB.ssh_ip)
res = ssh.execute("ssh %s@%s" % (
self.services["virtual_machine"]["username"],
self.virtual_machineB.ssh_ip
@ -1610,14 +1611,14 @@ class TestMultipleAccountsEgressRule(cloudstackTestCase):
"Authorizing egress rule for sec group ID: %s for ssh access"
% security_groupA.id)
# Authorize to only account not CIDR
user_secgrp_list = {self.accountB.account.name: security_groupB.name}
user_secgrp_list = {self.accountB.account.name: security_groupB.name}
egress_rule = security_groupA.authorizeEgress(
self.apiclient,
self.services["sg_account"],
account=self.accountA.account.name,
domainid=self.accountA.account.domainid,
user_secgrp_list=user_secgrp_list
user_secgrp_list=user_secgrp_list
)
self.assertEqual(
@ -1734,7 +1735,7 @@ class TestMultipleAccountsEgressRule(cloudstackTestCase):
try:
self.debug("SSHing into VB type B from VM A")
self.debug("VM IP: %s" % self.virtual_machineB.ssh_ip)
self.debug("VM IP: %s" % self.virtual_machineB.ssh_ip)
res = ssh.execute("ssh %s@%s" % (
self.services["virtual_machine"]["username"],
@ -1965,6 +1966,7 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase):
)
return
@unittest.skip("Valid bug- ID: CS-12647")
class TestInvalidParametersForEgress(cloudstackTestCase):
@ -2329,12 +2331,12 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase):
)
vm = vms[0]
self.debug("Enabling host maintainance for ID: %s" % host.id)
self.debug("Enabling host maintainance for ID: %s" % vm.hostid)
cmd = prepareHostForMaintenance.prepareHostForMaintenanceCmd()
cmd.id = vm.hostid
self.apiclient.prepareHostForMaintenance(cmd)
self.debug("Canceling host maintainance for ID: %s" % host.id)
self.debug("Canceling host maintainance for ID: %s" % vm.hostid)
cmd = cancelHostMaintenance.cancelHostMaintenanceCmd()
cmd.id = vm.hostid
self.apiclient.cancelHostMaintenance(cmd)

View File

@ -47,8 +47,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"lbrule": {
"name": "SSH",

View File

@ -47,8 +47,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"lbrule": {
"name": "SSH",
@ -62,7 +62,7 @@ class Services:
"publicport": 22,
"protocol": "TCP"
},
"fw_rule":{
"fw_rule": {
"startport": 1,
"endport": 6000,
"cidr": '55.55.0.0/11',
@ -86,7 +86,7 @@ class Services:
"ostypeid": '946b031b-0e10-4f4a-a3fc-d212ae2ea07f',
"url": "http://download.cloud.com/releases/2.0.0/UbuntuServer-10-04-64bit.vhd.bz2",
"hypervisor": 'XenServer',
"format" : 'VHD',
"format": 'VHD',
"isfeatured": True,
"ispublic": True,
"isextractable": True,
@ -96,7 +96,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 100,
"mode":'advanced'
"mode": 'advanced'
}

View File

@ -47,8 +47,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"network_offering": {
"name": 'Network offering-VR services',
@ -57,16 +57,16 @@ class Services:
"supportedservices": 'Dhcp,Dns,SourceNat,PortForwarding,Vpn,Firewall,Lb,UserData,StaticNat',
"traffictype": 'GUEST',
"availability": 'Optional',
"serviceProviderList" : {
"serviceProviderList": {
"Dhcp": 'VirtualRouter',
"Dns": 'VirtualRouter',
"SourceNat": 'VirtualRouter',
"PortForwarding": 'VirtualRouter',
"Vpn": 'VirtualRouter',
"Firewall": 'VirtualRouter',
"Lb": 'VirtualRouter',
"UserData": 'VirtualRouter',
"StaticNat": 'VirtualRouter',
"Vpn": 'VirtualRouter',
"Firewall": 'VirtualRouter',
"Lb": 'VirtualRouter',
"UserData": 'VirtualRouter',
"StaticNat": 'VirtualRouter',
},
},
"network_offering_netscaler": {
@ -76,7 +76,7 @@ class Services:
"supportedservices": 'Dhcp,Dns,SourceNat,PortForwarding,Vpn,Firewall,Lb,UserData,StaticNat',
"traffictype": 'GUEST',
"availability": 'Optional',
"serviceProviderList" : {
"serviceProviderList": {
"Dhcp": 'VirtualRouter',
"Dns": 'VirtualRouter',
"SourceNat": 'VirtualRouter',
@ -118,7 +118,7 @@ class Services:
"publicport": 66,
"protocol": "TCP"
},
"fw_rule":{
"fw_rule": {
"startport": 1,
"endport": 6000,
"cidr": '55.55.0.0/11',
@ -140,7 +140,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode":'advanced'
"mode": 'advanced'
}
@ -245,7 +245,7 @@ class TestNOVirtualRouter(cloudstackTestCase):
self.debug("Created n/w offering with ID: %s" %
self.network_offering.id)
# Enable Network offering
# Enable Network offering
self.network_offering.update(self.apiclient, state='Enabled')
# Creating network using the network offering created
@ -257,7 +257,7 @@ class TestNOVirtualRouter(cloudstackTestCase):
accountid=self.account.account.name,
domainid=self.account.account.domainid,
networkofferingid=self.network_offering.id,
zoneid=self.zone.id
zoneid=self.zone.id
)
self.debug("Created network with ID: %s" % self.network.id)
@ -334,7 +334,7 @@ class TestNOVirtualRouter(cloudstackTestCase):
ip_with_nat_rule.ipaddress.ipaddress)
NATRule.create(
self.apiclient,
virtual_machine,
virtual_machine,
self.services["natrule"],
ipaddressid=ip_with_nat_rule.ipaddress.id
)
@ -488,7 +488,7 @@ class TestNOVirtualRouter(cloudstackTestCase):
self.debug("Created n/w offering with ID: %s" %
self.network_offering.id)
# Enable Network offering
# Enable Network offering
self.network_offering.update(self.apiclient, state='Enabled')
# Creating network using the network offering created
@ -500,7 +500,7 @@ class TestNOVirtualRouter(cloudstackTestCase):
accountid=self.account.account.name,
domainid=self.account.account.domainid,
networkofferingid=self.network_offering.id,
zoneid=self.zone.id
zoneid=self.zone.id
)
self.debug("Created network with ID: %s" % self.network.id)
@ -705,7 +705,7 @@ class TestNOVirtualRouter(cloudstackTestCase):
vpns = Vpn.list(
self.apiclient,
publicipid=src_nat.id,
listall=True,
listall=True,
)
self.assertEqual(
@ -809,7 +809,6 @@ class TestNOWithNetscaler(cloudstackTestCase):
# address for different public port ranges.
# 9. On source NAT ipaddress, we should NOT be allowed to Enable VPN.
# Create a network offering with all virtual router services enabled
self.debug(
"Creating n/w offering with all services in VR & conserve mode:ON"
@ -1080,7 +1079,6 @@ class TestNOWithNetscaler(cloudstackTestCase):
# address for different public port ranges.
# 9. On source NAT ipaddress, we should be allowed to Enable VPN.
# Create a network offering with all virtual router services enabled
self.debug(
"Creating n/w offering with all services in VR & conserve mode:ON"

View File

@ -68,8 +68,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"virtual_machine": {
"displayname": "Test VM",
@ -89,7 +89,7 @@ class Services:
"ostypeid": 'f9b709f2-e0fc-4c0f-80f1-b0494168f58d',
"url": "http://download.cloud.com/releases/2.0.0/UbuntuServer-10-04-64bit.vhd.bz2",
"hypervisor": 'XenServer',
"format" : 'VHD',
"format": 'VHD',
"isfeatured": True,
"ispublic": True,
"isextractable": True,
@ -107,7 +107,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode":'advanced'
"mode": 'advanced'
}
@ -169,11 +169,14 @@ class TestUserProjectCreation(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
def test_01_admin_project_creation(self):
"""Test create project as a domain admin and domain user
"""
<<<<<<< HEAD
=======
tags = ["advanced", "basic", "sg", "eip", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Check if 'allow.user.create.projects' configuration is true
# 2. Create a Project as domain admin
@ -263,6 +266,7 @@ class TestUserProjectCreation(cloudstackTestCase):
"Check list project response returns a valid project"
)
return
@unittest.skip("Known bug-able to create project as a domain user")
def test_02_user_project_creation(self):
"""Test create project as a domain admin and domain user
@ -390,10 +394,13 @@ class TestProjectInviteRequired(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
def test_03_add_user_to_project(self):
"""Add user to project when 'project.invite.required' is false"""
<<<<<<< HEAD
=======
tags = ["advanced", "basic", "sg", "eip", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following:
# 1. Create a Project
# 2. Add users to the project. Verify user is added to project
@ -1148,6 +1155,7 @@ class TestProjectInviteRequired(cloudstackTestCase):
"Check for a valid list accounts response"
)
return
@unittest.skip("Requires SMPT configs")
def test_09_invite_to_project_by_email(self):
"""Test invite user to project by email"""

View File

@ -25,6 +25,7 @@ from integration.lib.base import *
from integration.lib.common import *
import datetime
class Services:
"""Test Resource Limits Services
"""
@ -60,8 +61,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Tiny Disk Offering",
@ -125,10 +126,10 @@ class TestProjectLimits(cloudstackTestCase):
domainid=cls.domain.id
)
cls._cleanup = [
cls.admin,
cls.user,
cls.domain
]
cls.admin,
cls.user,
cls.domain
]
return
@classmethod
@ -300,6 +301,7 @@ class TestProjectLimits(cloudstackTestCase):
projectid=project.id
)
return
@unittest.skip("No provision for updating resource limits from account through API")
def test_02_project_limits_normal_user(self):
""" Test project limits
@ -540,7 +542,7 @@ class TestResourceLimitsProject(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
0, # Instance
0, # Instance
max=2,
projectid=self.project.id
)
@ -589,7 +591,11 @@ class TestResourceLimitsProject(cloudstackTestCase):
def test_04_publicip_per_project(self):
"""Test Public IP limit per project
"""
<<<<<<< HEAD
=======
tags = ["advanced", "eip", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. set max no of IPs per project to 2.
# 2. Create an account in this domain
@ -604,7 +610,7 @@ class TestResourceLimitsProject(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
1, # Public Ip
1, # Public Ip
max=2,
projectid=self.project.id
)
@ -688,7 +694,7 @@ class TestResourceLimitsProject(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
3, # Snapshot
3, # Snapshot
max=1,
projectid=self.project.id
)
@ -765,7 +771,7 @@ class TestResourceLimitsProject(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
2, # Volume
2, # Volume
max=2,
projectid=self.project.id
)
@ -800,8 +806,13 @@ class TestResourceLimitsProject(cloudstackTestCase):
def test_07_templates_per_project(self):
"""Test Templates limit per project
"""
<<<<<<< HEAD
# Validate the following
=======
tags = ["advanced", "basic", "sg", "eip", "advancedns"]
# Validate the following
>>>>>>> 6d17e21... This commit has following fixes:
# 1. set max no of templates per project to 1.
# 2. Create a template in this project. Both template should be in
# ready state
@ -811,7 +822,7 @@ class TestResourceLimitsProject(cloudstackTestCase):
# Reset the volume limits
update_resource_limit(
self.apiclient,
2, # Volume
2, # Volume
max=5,
projectid=self.project.id
)
@ -821,7 +832,7 @@ class TestResourceLimitsProject(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
4, # Template
4, # Template
max=1,
projectid=self.project.id
)

View File

@ -26,6 +26,7 @@ from integration.lib.common import *
from marvin.remoteSSHClient import remoteSSHClient
import datetime
class Services:
"""Test Resource creation Services
"""
@ -61,8 +62,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Tiny Disk Offering",
@ -382,7 +383,11 @@ class TestNetwork(cloudstackTestCase):
def test_03_network_create(self):
""" Test create network in project
"""
<<<<<<< HEAD
=======
tags = ["advanced", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Create a project.
# 2. Add virtual/direct network resource to the project. User shared
@ -428,7 +433,7 @@ class TestNetwork(cloudstackTestCase):
projectid=project.id
)
self.debug("Created network with ID: %s" % network.id)
networks= Network.list(
networks = Network.list(
self.apiclient,
projectid=project.id,
listall=True
@ -586,8 +591,13 @@ class TestTemplates(cloudstackTestCase):
def test_04_public_template_use_in_project(self):
"""Test Templates creation in projects
"""
<<<<<<< HEAD
# Validate the following
=======
tags = ["advanced", "basic", "sg", "eip", "advancedns"]
# Validate the following
>>>>>>> 6d17e21... This commit has following fixes:
# 1. Create a project
# 2. Verify Public templates can be used without any restriction
# 3. Verify that template created in project can be used in project
@ -645,8 +655,13 @@ class TestTemplates(cloudstackTestCase):
def test_05_use_private_template_in_project(self):
"""Test use of private template in a project
"""
<<<<<<< HEAD
# Validate the following
=======
tags = ["advanced", "basic", "sg", "eip", "advancedns"]
# Validate the following
>>>>>>> 6d17e21... This commit has following fixes:
# 1. Create a project
# 2. Verify that in order to use somebodys Private template for vm
# creation in the project, permission to use the template has to
@ -964,7 +979,11 @@ class TestPublicIpAddress(cloudstackTestCase):
def test_07_associate_public_ip(self):
"""Test associate public IP within the project
"""
<<<<<<< HEAD
=======
tags = ["advanced", "eip", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Create a project
# 2. Add some public Ips to the project

View File

@ -26,6 +26,7 @@ from integration.lib.common import *
from marvin.remoteSSHClient import remoteSSHClient
import datetime
class Services:
"""Test Snapshots Services
"""
@ -49,8 +50,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Small",
@ -107,7 +108,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode":'advanced'
"mode": 'advanced'
}
@ -1077,7 +1078,11 @@ class TestLBRuleUsage(cloudstackTestCase):
def test_01_lb_usage(self):
"""Test Create/Delete a LB rule and verify correct usage is recorded
"""
<<<<<<< HEAD
=======
tags = ["advanced", "eip", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Acquire a IP for this account. lb.rule.create event is registered
# for this account in cloud.usage_event table
@ -1435,7 +1440,11 @@ class TestNatRuleUsage(cloudstackTestCase):
def test_01_nat_usage(self):
"""Test Create/Delete a PF rule and verify correct usage is recorded
"""
<<<<<<< HEAD
=======
tags = ["advanced", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Acquire a IP for this account
# 2. Create a PF rule on the IP associated with this account.
@ -1618,7 +1627,11 @@ class TestVpnUsage(cloudstackTestCase):
def test_01_vpn_usage(self):
"""Test Create/Delete a VPN and verify correct usage is recorded
"""
<<<<<<< HEAD
=======
tags = ["advanced", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Enable VPN for this IP. vpn.add.user event is registered for this
# account in cloud.usage_event table

View File

@ -76,8 +76,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"virtual_machine": {
"displayname": "Test VM",
@ -95,7 +95,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode":'advanced'
"mode": 'advanced'
}
@ -443,7 +443,7 @@ class TestCrossDomainAccountAdd(cloudstackTestCase):
"Check project name from list response"
)
self.debug("Adding user: %s from domain: %s to project: %s" %(
self.debug("Adding user: %s from domain: %s to project: %s" % (
self.user.account.name,
self.user.account.domainid,
project.id
@ -576,6 +576,7 @@ class TestDeleteAccountWithProject(cloudstackTestCase):
self.account.account.name)
return
@unittest.skip("Deleting domain doesn't cleanup account")
class TestDeleteDomainWithProject(cloudstackTestCase):

View File

@ -25,6 +25,7 @@ from integration.lib.base import *
from integration.lib.common import *
import datetime
class Services:
"""Test Resource Limits Services
"""
@ -47,8 +48,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Small",
@ -81,6 +82,7 @@ class Services:
"mode": 'advanced',
}
class TestResourceLimitsAccount(cloudstackTestCase):
@classmethod
@ -153,7 +155,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
def test_01_vm_per_account(self):
"""Test VM limit per account
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Set user_vm=1 limit for account 1.
@ -167,7 +169,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
0, # Instance
0, # Instance
account=self.account_1.account.name,
domainid=self.account_1.account.domainid,
max=1
@ -246,7 +248,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
def test_02_publicip_per_account(self):
"""Test Public IP limit per account
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Set Public_IP= 2 limit for account 1.
@ -263,7 +265,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
1, # Public Ip
1, # Public Ip
account=self.account_1.account.name,
domainid=self.account_1.account.domainid,
max=2
@ -389,7 +391,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
def test_03_snapshots_per_account(self):
"""Test Snapshot limit per account
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Set snapshot= 2 limit for account 1.
@ -406,7 +408,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
3, # Snapshot
3, # Snapshot
account=self.account_1.account.name,
domainid=self.account_1.account.domainid,
max=1
@ -545,7 +547,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
def test_04_volumes_per_account(self):
"""Test Volumes limit per account
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Set volumes=2 limit for account 1.
@ -562,7 +564,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
2, # Volume
2, # Volume
account=self.account_1.account.name,
domainid=self.account_1.account.domainid,
max=2
@ -687,7 +689,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
def test_05_templates_per_account(self):
"""Test Templates limit per account
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Set templates=1 limit for account 1.
@ -702,7 +704,7 @@ class TestResourceLimitsAccount(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
4, # Template
4, # Template
account=self.account_1.account.name,
domainid=self.account_1.account.domainid,
max=1
@ -917,7 +919,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
def test_01_vm_per_domain(self):
"""Test VM limit per domain
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Set max VM per domain to 2
@ -931,7 +933,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
0, # Instance
0, # Instance
domainid=self.account.account.domainid,
max=2
)
@ -983,7 +985,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
def test_01_publicip_per_domain(self):
"""Test Public IP limit per domain
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. set max no of IPs per domain to 2.
@ -999,7 +1001,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
1, # Public Ip
1, # Public Ip
domainid=self.account.account.domainid,
max=2
)
@ -1053,7 +1055,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
def test_03_snapshots_per_domain(self):
"""Test Snapshot limit per domain
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. set max no of snapshots per domain to 1.
@ -1070,7 +1072,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
3, # Snapshot
3, # Snapshot
domainid=self.account.account.domainid,
max=1
)
@ -1136,7 +1138,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
def test_04_volumes_per_domain(self):
"""Test Volumes limit per domain
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. set max no of volume per domain to 1.
@ -1152,7 +1154,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
2, # Volume
2, # Volume
domainid=self.account.account.domainid,
max=2
)
@ -1189,7 +1191,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
def test_05_templates_per_domain(self):
"""Test Templates limit per domain
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. set max no of templates per domain to 2.
@ -1202,7 +1204,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
2, # Volume
2, # Volume
domainid=self.account.account.domainid,
max=5
)
@ -1213,7 +1215,7 @@ class TestResourceLimitsDomain(cloudstackTestCase):
# Set usage_vm=1 for Account 1
update_resource_limit(
self.apiclient,
4, # Template
4, # Template
domainid=self.account.account.domainid,
max=2
)
@ -1308,7 +1310,7 @@ class TestResources(cloudstackTestCase):
# Get Zone, Domain and templates
cls.zone = get_zone(cls.api_client, cls.services)
cls._cleanup = []
return
return
@classmethod
def tearDownClass(cls):
@ -1335,7 +1337,7 @@ class TestResources(cloudstackTestCase):
def test_01_zones(self):
"""Check the status of zones"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. List zones
@ -1344,7 +1346,7 @@ class TestResources(cloudstackTestCase):
zones = Zone.list(
self.apiclient,
id=self.zone.id,
listall=True
listall=True
)
self.assertEqual(
isinstance(zones, list),
@ -1361,7 +1363,7 @@ class TestResources(cloudstackTestCase):
def test_02_pods(self):
"""Check the status of pods"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. List pods
@ -1370,7 +1372,7 @@ class TestResources(cloudstackTestCase):
pods = Pod.list(
self.apiclient,
zoneid=self.zone.id,
listall=True
listall=True
)
self.assertEqual(
isinstance(pods, list),
@ -1387,7 +1389,7 @@ class TestResources(cloudstackTestCase):
def test_03_clusters(self):
"""Check the status of clusters"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. List clusters
@ -1396,7 +1398,7 @@ class TestResources(cloudstackTestCase):
clusters = Cluster.list(
self.apiclient,
zoneid=self.zone.id,
listall=True
listall=True
)
self.assertEqual(
isinstance(clusters, list),
@ -1413,7 +1415,7 @@ class TestResources(cloudstackTestCase):
def test_04_hosts(self):
"""Check the status of hosts"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. List hosts with type=Routing
@ -1423,7 +1425,7 @@ class TestResources(cloudstackTestCase):
self.apiclient,
zoneid=self.zone.id,
type='Routing',
listall=True
listall=True
)
self.assertEqual(
isinstance(hosts, list),
@ -1440,7 +1442,7 @@ class TestResources(cloudstackTestCase):
def test_05_storage_pools(self):
"""Check the status of Storage pools"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. List storage pools for the zone
@ -1449,7 +1451,7 @@ class TestResources(cloudstackTestCase):
storage_pools = StoragePool.list(
self.apiclient,
zoneid=self.zone.id,
listall=True
listall=True
)
self.assertEqual(
isinstance(storage_pools, list),
@ -1466,7 +1468,7 @@ class TestResources(cloudstackTestCase):
def test_06_secondary_storage(self):
"""Check the status of secondary storage"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. List secondary storage
@ -1476,7 +1478,7 @@ class TestResources(cloudstackTestCase):
self.apiclient,
zoneid=self.zone.id,
type='SecondaryStorage',
listall=True
listall=True
)
self.assertEqual(
isinstance(sec_storages, list),

View File

@ -82,7 +82,7 @@ class Services:
"publicport": 2222,
"protocol": 'TCP',
},
"fw_rule":{
"fw_rule": {
"startport": 1,
"endport": 6000,
"cidr": '55.55.0.0/11',
@ -90,7 +90,7 @@ class Services:
},
"ostypeid": '5776c0d2-f331-42db-ba3a-29f1f8319bc9',
# Used for Get_Template : CentOS 5.3 (64 bit)
"mode": 'advanced', # Networking mode: Advanced, basic
"mode": 'advanced', # Networking mode: Advanced, basic
}
@ -436,7 +436,7 @@ class TestRouterServices(cloudstackTestCase):
)
self.debug("network.gc.wait: %s" % gcwait[0].value)
total_wait = int(gcinterval[0].value) + int (gcwait[0].value)
total_wait = int(gcinterval[0].value) + int(gcwait[0].value)
# Router is stopped after (network.gc.interval *2) time. Wait for
# (network.gc.interval+network.gc.wait) * 2 for moving router to 'Stopped'
time.sleep(total_wait * 2)
@ -580,7 +580,6 @@ class TestRouterServices(cloudstackTestCase):
return
class TestRouterStopCreatePF(cloudstackTestCase):
@classmethod
@ -791,6 +790,7 @@ class TestRouterStopCreatePF(cloudstackTestCase):
)
return
class TestRouterStopCreateLB(cloudstackTestCase):
@classmethod
@ -1223,4 +1223,3 @@ class TestRouterStopCreateFW(cloudstackTestCase):
"Check public IP address"
)
return

View File

@ -37,7 +37,7 @@ class Services:
def __init__(self):
self.services = {
"disk_offering":{
"disk_offering": {
"displaytext": "Small",
"name": "Small",
"disksize": 1
@ -65,15 +65,15 @@ class Services:
},
"host": {
"publicport": 22,
"username": "root", # Host creds for SSH
"username": "root", # Host creds for SSH
"password": "fr3sca",
},
"service_offering": {
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"security_group": {
"name": 'SSH',
@ -93,7 +93,7 @@ class Services:
# CentOS 5.3 (64-bit)
"sleep": 60,
"timeout": 10,
"mode":'basic',
"mode": 'basic',
# Networking mode: Basic or Advanced
}
@ -767,7 +767,7 @@ class TestDhcpOnlyRouter(cloudstackTestCase):
zoneid=router.zoneid,
type='Routing',
state='Up',
virtualmachineid=self.virtual_machine.id
id=router.hostid
)
self.assertEqual(
isinstance(hosts, list),
@ -1534,7 +1534,7 @@ class TestIngressRule(cloudstackTestCase):
result = security_group.revoke(
self.apiclient,
id = icmp_rule["ruleid"]
id=icmp_rule["ruleid"]
)
self.debug("Revoke ingress rule result: %s" % result)

View File

@ -25,6 +25,7 @@ from integration.lib.base import *
from integration.lib.common import *
from marvin.remoteSSHClient import remoteSSHClient
class Services:
"""Test Snapshots Services
"""
@ -44,8 +45,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 200, # in MHz
"memory": 256, # In MBs
"cpuspeed": 200, # in MHz
"memory": 256, # In MBs
},
"disk_offering": {
"displaytext": "Small Disk",
@ -71,7 +72,7 @@ class Services:
"recurring_snapshot": {
"intervaltype": 'HOURLY',
# Frequency of snapshots
"maxsnaps": 1, # Should be min 2
"maxsnaps": 1, # Should be min 2
"schedule": 1,
"timezone": 'US/Arizona',
# Timezone Formats - http://cloud.mindtouch.us/CloudStack_Documentation/Developer's_Guide%3A_CloudStack
@ -84,7 +85,7 @@ class Services:
},
"diskdevice": "/dev/xvda",
"diskname": "TestDiskServ",
"size": 1, # GBs
"size": 1, # GBs
"mount_dir": "/mnt/tmp",
"sub_dir": "test",
@ -96,7 +97,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode" : 'advanced', # Networking mode: Advanced, Basic
"mode": 'advanced', # Networking mode: Advanced, Basic
}
@ -165,7 +166,7 @@ class TestCreateVMsnapshotTemplate(cloudstackTestCase):
def test_01_createVM_snapshotTemplate(self):
"""Test create VM, Snapshot and Template
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Deploy VM using default template, small service offering
# and small data disk offering.
@ -473,7 +474,7 @@ class TestAccountSnapshotClean(cloudstackTestCase):
def test_02_accountSnapshotClean(self):
"""Test snapshot cleanup after account deletion
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. listAccounts API should list out the newly created account
# 2. listVirtualMachines() command should return the deployed VM.
@ -664,13 +665,13 @@ class TestAccountSnapshotClean(cloudstackTestCase):
id=self.account.account.id
)
self.assertEqual(
accounts,
None,
"List accounts should return empty list after account deletion"
)
self.assertEqual(
accounts,
None,
"List accounts should return empty list after account deletion"
)
uuids = []
uuids = []
for host in hosts:
# hosts[0].name = "nfs://192.168.100.21/export/test"
parse_url = (host.name).split('/')
@ -804,7 +805,7 @@ class TestSnapshotDetachedDisk(cloudstackTestCase):
def test_03_snapshot_detachedDisk(self):
"""Test snapshot from detached disk
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. login in VM and write some data on data disk(use fdisk to
# partition datadisk,fdisk /dev/sdb, and make filesystem using
@ -863,7 +864,7 @@ class TestSnapshotDetachedDisk(cloudstackTestCase):
self.services["sub_lvl_dir2"],
self.services["random_data"]
),
"sync",
"sync",
]
for c in cmds:
self.debug(ssh_client.execute(c))
@ -1076,7 +1077,7 @@ class TestSnapshotLimit(cloudstackTestCase):
def test_04_snapshot_limit(self):
"""Test snapshot limit in snapshot policies
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Perform hourly recurring snapshot on the root disk of VM and keep
# the maxsnapshots as 1
@ -1159,7 +1160,7 @@ class TestSnapshotLimit(cloudstackTestCase):
self.services["recurring_snapshot"]["maxsnaps"],
"Check maximum number of recurring snapshots retained"
)
snapshot = snapshots[0]
snapshot = snapshots[0]
# Sleep to ensure that snapshot is reflected in sec storage
time.sleep(self.services["sleep"])
@ -1328,7 +1329,7 @@ class TestSnapshotEvents(cloudstackTestCase):
def test_05_snapshot_events(self):
"""Test snapshot events
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Perform snapshot on the root disk of this VM and check the events/alerts.
# 2. delete the snapshots and check the events/alerts

View File

@ -49,8 +49,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Small",
@ -73,13 +73,13 @@ class Services:
"templates": {
# Configs for different Template formats
# For Eg. raw image, zip etc
0:{
0: {
"displaytext": "Public Template",
"name": "Public template",
"ostypeid": '5776c0d2-f331-42db-ba3a-29f1f8319bc9',
"url": "http://download.cloud.com/releases/2.0.0/UbuntuServer-10-04-64bit.vhd.bz2",
"hypervisor": 'XenServer',
"format" : 'VHD',
"format": 'VHD',
"isfeatured": True,
"ispublic": True,
"isextractable": True,
@ -92,11 +92,11 @@ class Services:
"templatefilter": 'self',
},
"templatefilter": 'self',
"destzoneid": 2, # For Copy template (Destination zone)
"destzoneid": 2, # For Copy template (Destination zone)
"ostypeid": '5776c0d2-f331-42db-ba3a-29f1f8319bc9',
"sleep": 60,
"timeout": 10,
"mode": 'advanced', # Networking mode: Advanced, basic
"mode": 'advanced', # Networking mode: Advanced, basic
}
@ -162,7 +162,7 @@ class TestCreateTemplate(cloudstackTestCase):
def test_01_create_template(self):
"""Test create public & private template
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following:
# 1. Upload a templates in raw img format. Create a Vm instances from
# raw img template.
@ -331,7 +331,7 @@ class TestTemplates(cloudstackTestCase):
raise Exception("List volumes failed.")
time.sleep(5)
timeout = timeout -1
timeout = timeout - 1
cls.volume = list_volume[0]
@ -378,7 +378,7 @@ class TestTemplates(cloudstackTestCase):
def test_01_create_template_volume(self):
"""Test Create template from volume
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following:
# 1. Deploy new VM using the template created from Volume
@ -417,7 +417,7 @@ class TestTemplates(cloudstackTestCase):
def test_02_copy_template(self):
"""Test for copy template from one zone to another"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. copy template should be successful and
@ -476,7 +476,7 @@ class TestTemplates(cloudstackTestCase):
def test_03_delete_template(self):
"""Test Delete template
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following:
# 1. Create a template and verify it is shown in list templates response
@ -531,7 +531,7 @@ class TestTemplates(cloudstackTestCase):
def test_04_template_from_snapshot(self):
"""Create Template from snapshot
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 2. Snapshot the Root disk

View File

@ -26,6 +26,7 @@ from integration.lib.common import *
from marvin.remoteSSHClient import remoteSSHClient
import datetime
class Services:
"""Test Snapshots Services
"""
@ -103,7 +104,7 @@ class Services:
# Cent OS 5.3 (64 bit)
"sleep": 60,
"timeout": 10,
"mode":'advanced'
"mode": 'advanced'
}
@ -1318,7 +1319,11 @@ class TestNatRuleUsage(cloudstackTestCase):
def test_01_nat_usage(self):
"""Test Create/Delete a PF rule and verify correct usage is recorded
"""
<<<<<<< HEAD
=======
tags = ["advanced", "advancedns"]
>>>>>>> 6d17e21... This commit has following fixes:
# Validate the following
# 1. Acquire a IP for this account
# 2. Create a PF rule on the IP associated with this account.

View File

@ -50,8 +50,8 @@ class Services:
"name": "Tiny Instance",
"displaytext": "Tiny Instance",
"cpunumber": 1,
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
"cpuspeed": 100, # in MHz
"memory": 64, # In MBs
},
"disk_offering": {
"displaytext": "Small",
@ -143,7 +143,7 @@ class TestAttachVolume(cloudstackTestCase):
def test_01_volume_attach(self):
"""Test Attach volumes (max capacity)
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Deploy a vm and create 5 data disk
# 2. Attach all the created Volume to the vm.
@ -295,7 +295,7 @@ class TestAttachVolume(cloudstackTestCase):
def test_02_volume_attach_max(self):
"""Test attach volumes (more than max) to an instance
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Attach one more data volume to VM (Already 5 attached)
@ -426,7 +426,7 @@ class TestAttachDetachVolume(cloudstackTestCase):
def test_01_volume_attach_detach(self):
"""Test Volume attach/detach to VM (5 data volumes)
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Deploy a vm and create 5 data disk
@ -674,7 +674,7 @@ class TestAttachVolumeISO(cloudstackTestCase):
def test_01_volume_iso_attach(self):
"""Test Volumes and ISO attach
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Create and attach 5 data volumes to VM
@ -870,7 +870,7 @@ class TestVolumes(cloudstackTestCase):
def test_01_attach_volume(self):
"""Attach a created Volume to a Running VM
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Create a data volume.
# 2. List Volumes should not have vmname and virtualmachineid fields in
@ -954,7 +954,7 @@ class TestVolumes(cloudstackTestCase):
def test_02_detach_volume(self):
"""Detach a Volume attached to a VM
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Data disk should be detached from instance
@ -1002,7 +1002,7 @@ class TestVolumes(cloudstackTestCase):
def test_03_delete_detached_volume(self):
"""Delete a Volume unattached to an VM
"""
tags = ["advanced","advancedns"]
tags = ["advanced", "advancedns"]
# Validate the following
# 1. volume should be deleted successfully and listVolume should not
# contain the deleted volume details.