Applying tags as attribute decorators for nose

This commit is contained in:
Prasanna Santhanam 2012-07-23 11:44:27 +05:30
parent fe3e5cb657
commit 232f6f2038
5 changed files with 45 additions and 39 deletions

View File

@ -134,11 +134,11 @@ class TestAccounts(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_create_account(self):
"""Test Create Account and user for that account
"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Create an Account. Verify the account is created.
@ -269,11 +269,11 @@ class TestRemoveUserFromAccount(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_user_remove_VM_running(self):
"""Test Remove one user from the account
"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Create an account with 2 users.
@ -371,11 +371,11 @@ class TestRemoveUserFromAccount(cloudstackTestCase):
return
@unittest.skip("Open Questions")
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_02_remove_all_users(self):
"""Test Remove both users from the account
"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Remove both the users from the account.
@ -530,10 +530,10 @@ class TestNonRootAdminsPrivileges(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_non_root_admin_Privileges(self):
"""Test to verify Non Root admin previleges"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Create few accounts/users in ROOT domain
@ -649,10 +649,10 @@ class TestServiceOfferingSiblings(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_service_offering_siblings(self):
"""Test to verify service offerings at same level in hierarchy"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Verify service offering is visible for domain_1
@ -765,10 +765,10 @@ class TestServiceOfferingHierarchy(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_service_offering_hierarchy(self):
"""Test to verify service offerings at same level in hierarchy"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Verify service offering is visible for domain_1
@ -897,10 +897,10 @@ class TesttemplateHierarchy(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_template_hierarchy(self):
"""Test to verify template at same level in hierarchy"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Verify template is visible for domain_1
@ -1058,11 +1058,11 @@ class TestAddVmToSubDomain(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "basic", "eip", "advancedns", "sg"])
def test_01_add_vm_to_subdomain(self):
""" Test Sub domain allowed to launch VM when a Domain level zone is
created"""
tags = ["advanced", "basic", "eip", "advancedns", "sg"]
# Validate the following
# 1. Verify VM created by Account_1 is in Running state

View File

@ -179,11 +179,11 @@ class TestSnapshots(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "advancedns"])
def test_01_volume_from_snapshot(self):
"""TS_BUG_001-Test Creating snapshot from volume having spaces in name(KVM)
"""
tags = ["advanced", "advancedns"]
# Validate the following
#1. Create a virtual machine and data volume
@ -451,11 +451,11 @@ class TestTemplate(cloudstackTestCase):
return
@attr(tags = ["advanced", "advancedns", "basic", "sg"])
def test_01_create_template(self):
"""TS_BUG_002-Test to create and deploy VM using password enabled template
"""
tags = ["advanced", "advancedns", "basic", "sg"]
# Validate the following:
#1. Create a password enabled template
@ -596,10 +596,10 @@ class TestNATRules(cloudstackTestCase):
cleanup_resources(self.apiclient, self.cleanup)
return
@attr(tags = ["advanced"])
def test_01_firewall_rules_port_fw(self):
""""Checking firewall rules deletion after static NAT disable"""
tags = ["advanced"]
# Validate the following:
#1. Enable static NAT for a VM
@ -797,11 +797,11 @@ class TestRouters(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "advancedns"])
def test_01_list_routers_admin(self):
"""TS_BUG_007-Check listRouters() using Admin User
"""
tags = ["advanced", "advancedns"]
# Validate the following
# 1. PreReq: have rounters that are owned by other account
@ -907,11 +907,11 @@ class TestRouterRestart(cloudstackTestCase):
self.apiclient = self.testClient.getApiClient()
return
@attr(tags = ["advanced", "basic", "sg", "advancedns", "eip"])
def test_01_restart_network_cleanup(self):
"""TS_BUG_008-Test restart network
"""
tags = ["advanced", "basic", "sg", "advancedns", "eip"]
# Validate the following
# 1. When cleanup = true, router is destroyed and a new one created
@ -1068,11 +1068,11 @@ class TestTemplates(cloudstackTestCase):
return
@attr(tags = ["advanced", "advancedns", "basic", "sg", "eip"])
def test_01_check_template_size(self):
"""TS_BUG_009-Test the size of template created from root disk
"""
tags = ["advanced", "advancedns", "basic", "sg", "eip"]
# Validate the following:
# 1. Deploy new VM using the template created from Volume
@ -1095,11 +1095,11 @@ class TestTemplates(cloudstackTestCase):
)
return
@attr(tags = ["advanced", "advancedns", "basic", "sg", "eip"])
def test_02_check_size_snapshotTemplate(self):
"""TS_BUG_010-Test check size of snapshot and template
"""
tags = ["advanced", "advancedns", "basic", "sg", "eip"]
# Validate the following
# 1. Deploy VM using default template, small service offering
@ -1175,11 +1175,11 @@ class TestTemplates(cloudstackTestCase):
)
return
@attr(tags = ["advanced", "advancedns", "basic", "sg", "eip"])
def test_03_resuse_template_name(self):
"""TS_BUG_011-Test Reusing deleted template name
"""
tags = ["advanced", "advancedns", "basic", "sg", "eip"]
# Validate the following
# 1. Deploy VM using default template, small service offering

View File

@ -192,11 +192,11 @@ class TestDefaultSecurityGroupEgress(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_deployVM_InDefaultSecurityGroup(self):
"""Test deploy VM in default security group with no egress rules
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. Deploy a VM.
@ -349,11 +349,11 @@ class TestAuthorizeIngressRule(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_authorizeIngressRule(self):
"""Test authorize ingress rule
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
@ -507,11 +507,11 @@ class TestDefaultGroupEgress(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_01_default_group_with_egress(self):
"""Test default group with egress rule before VM deploy and ping, ssh
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
@ -708,12 +708,12 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_01_default_group_with_egress(self):
""" Test default group with egress rule added after vm deploy and ping,
ssh test
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
@ -891,11 +891,11 @@ class TestRevokeEgressRule(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_revoke_egress_rule(self):
"""Test revoke security group egress rule
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
@ -1153,11 +1153,11 @@ class TestInvalidAccountAuthroize(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_invalid_account_authroize(self):
"""Test invalid account authroize
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
@ -1281,11 +1281,11 @@ class TestMultipleAccountsEgressRuleNeg(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_multiple_account_egress_rule_negative(self):
"""Test multiple account egress rules negative case
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user A
@ -1529,11 +1529,11 @@ class TestMultipleAccountsEgressRule(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_multiple_account_egress_rule_positive(self):
"""Test multiple account egress rules positive case
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user A
@ -1820,11 +1820,11 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_start_stop_vm_egress(self):
""" Test stop start Vm with egress rules
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
@ -2032,11 +2032,11 @@ class TestInvalidParametersForEgress(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_invalid_parameters(self):
""" Test invalid parameters for egress rules
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createUserAccount
@ -2219,12 +2219,11 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase):
return
@attr(tags = ["sg", "eip"])
def test_egress_after_host_maintainance(self):
"""Test maintenance case for egress
"""
tags = ["sg", "eip"]
# Validate the following:
# 1. createaccount of type user
# 2. createsecuritygroup (ssh) for this account

View File

@ -177,11 +177,13 @@ class TestEIP(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["eip"])
@unittest.skip("skipped")
def test_01_eip_by_deploying_instance(self):
"""Test EIP by deploying an instance
"""
tags = ["eip"]
# Validate the following
# 1. Instance gets an IP from GUEST IP range.
@ -344,11 +346,12 @@ class TestEIP(cloudstackTestCase):
(self.services["netscaler"]["ipaddress"], e))
return
@attr(tags = ["eip"])
@unittest.skip("skipped")
def test_02_acquire_ip_enable_static_nat(self):
"""Test associate new IP and enable static NAT for new IP and the VM
"""
tags = ["eip"]
# Validate the following
# 1. user_ip_address.is_system = 0 & user_ip_address.one_to_one_nat=1
@ -488,11 +491,12 @@ class TestEIP(cloudstackTestCase):
(self.services["netscaler"]["ipaddress"], e))
return
@attr(tags = ["eip"])
@unittest.skip("skipped")
def test_03_disable_static_nat(self):
"""Test disable static NAT and release EIP acquired
"""
tags = ["eip"]
# Validate the following
# 1. Disable static NAT. Disables one-to-one NAT and releases EIP
@ -687,11 +691,12 @@ class TestEIP(cloudstackTestCase):
(self.services["netscaler"]["ipaddress"], e))
return
@attr(tags = ["eip"])
@unittest.skip("skipped")
def test_04_disable_static_nat_system(self):
"""Test disable static NAT with system = True
"""
tags = ["eip"]
# Validate the following
# 1. Try to disassociate/disable static NAT on EIP where is_system=1
@ -756,11 +761,12 @@ class TestEIP(cloudstackTestCase):
self.debug("Disassociate system IP failed")
return
@attr(tags = ["eip"])
@unittest.skip("skipped")
def test_05_destroy_instance(self):
"""Test EIO after destroying instance
"""
tags = ["eip"]
# Validate the following
# 1. Destroy instance. Destroy should result in is_system=0 for EIP
@ -994,11 +1000,11 @@ class TestELB(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["eip"])
def test_01_elb_create(self):
"""Test ELB by creating a LB rule
"""
tags = ["eip"]
# Validate the following
# 1. Deploy 2 instances
@ -1168,11 +1174,11 @@ class TestELB(cloudstackTestCase):
(self.services["netscaler"]["ipaddress"], e))
return
@attr(tags = ["eip"])
def test_02_elb_acquire_and_create(self):
"""Test ELB by acquiring IP and then creating a LB rule
"""
tags = ["eip"]
# Validate the following
# 1. Deploy 2 instances
@ -1318,11 +1324,11 @@ class TestELB(cloudstackTestCase):
return
@attr(tags = ["eip"])
def test_03_elb_delete_lb_system(self):
"""Test delete LB rule generated with public IP with is_system = 1
"""
tags = ["eip"]
# Validate the following
# 1. Deleting LB rule should release EIP where is_system=1
@ -1396,11 +1402,12 @@ class TestELB(cloudstackTestCase):
(self.services["netscaler"]["ipaddress"], e))
return
@attr(tags = ["eip"])
@unittest.skip("valid bug : http://bugs.cloudstack.org/browse/CS-15077 : ListPublicIPAddress failing")
def test_04_delete_lb_on_eip(self):
"""Test delete LB rule generated on EIP
"""
tags = ["eip"]
# Validate the following
# 1. Deleting LB rule won't release EIP where is_system=0

View File

@ -169,11 +169,11 @@ class TestHighAvailability(cloudstackTestCase):
raise Exception("Warning: Exception during cleanup : %s" % e)
return
@attr(tags = ["advanced", "advancedns"])
def test_01_host_maintenance_mode(self):
"""Test host maintenance mode
"""
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Create Vms. Acquire IP. Create port forwarding & load balancing
@ -560,11 +560,11 @@ class TestHighAvailability(cloudstackTestCase):
)
return
@attr(tags = ["advanced", "advancedns"])
def test_02_host_maintenance_mode_with_activities(self):
"""Test host maintenance mode with activities
"""
tags = ["advanced", "advancedns"]
# Validate the following
# 1. Create Vms. Acquire IP. Create port forwarding & load balancing