Unit tests for the DB API
-
class AggregateDBApiTestCase(methodName='runTest')
Bases: nova.test.TestCase
-
setUp()
-
test_aggregate_create()
Ensure aggregate can be created with no metadata.
-
test_aggregate_create_avoid_name_conflict()
Test we can avoid conflict on deleted aggregates.
-
test_aggregate_create_delete_create_with_metadata()
Ensure aggregate metadata is deleted bug 1052479.
-
test_aggregate_create_low_privi_context()
Ensure right context is applied when creating aggregate.
-
test_aggregate_create_raise_exist_exc()
Ensure aggregate names are distinct.
-
test_aggregate_create_with_metadata()
Ensure aggregate can be created with metadata.
-
test_aggregate_delete()
Ensure we can delete an aggregate.
-
test_aggregate_delete_raise_not_found()
Ensure AggregateNotFound is raised when deleting an aggregate.
-
test_aggregate_get()
Ensure we can get aggregate with all its relations.
-
test_aggregate_get_all()
Ensure we can get all aggregates.
-
test_aggregate_get_all_non_deleted()
Ensure we get only non-deleted aggregates.
-
test_aggregate_get_by_host()
Ensure we can get aggregates by host.
-
test_aggregate_get_by_host_not_found()
Ensure AggregateHostNotFound is raised with unknown host.
-
test_aggregate_get_by_host_with_key()
Ensure we can get aggregates by host.
-
test_aggregate_get_raise_not_found()
Ensure AggregateNotFound is raised when getting an aggregate.
-
test_aggregate_host_add()
Ensure we can add host to the aggregate.
-
test_aggregate_host_add_deleted()
Ensure we can add a host that was previously deleted.
-
test_aggregate_host_add_duplicate_raise_exist_exc()
Ensure we cannot add host to the same aggregate.
-
test_aggregate_host_add_duplicate_works()
Ensure we can add host to distinct aggregates.
-
test_aggregate_host_add_raise_not_found()
Ensure AggregateFound when adding a host.
-
test_aggregate_host_delete()
Ensure we can add host to the aggregate.
-
test_aggregate_host_delete_raise_not_found()
Ensure AggregateHostNotFound is raised when deleting a host.
-
test_aggregate_metadata_add()
Ensure we can add metadata for the aggregate.
-
test_aggregate_metadata_delete()
Ensure we can delete metadata for the aggregate.
-
test_aggregate_metadata_delete_raise_not_found()
Ensure AggregateMetadataNotFound is raised when deleting.
-
test_aggregate_metadata_get_raise_not_found()
Ensure AggregateNotFound is raised when getting metadata.
-
test_aggregate_metadata_update()
Ensure we can update metadata for the aggregate.
-
test_aggregate_metdata_get_by_host()
Ensure we can get aggregates by host.
-
test_aggregate_metdata_get_by_host_with_key()
Ensure we can get aggregates by host.
-
test_aggregate_update()
Ensure an aggregate can be updated.
-
test_aggregate_update_raise_not_found()
Ensure AggregateNotFound is raised when updating an aggregate.
-
test_aggregate_update_with_existing_metadata()
Ensure an aggregate can be updated with existing metadata.
-
test_aggregate_update_with_metadata()
Ensure an aggregate can be updated with metadata.
-
class CapacityTestCase(methodName='runTest')
Bases: nova.test.TestCase
-
setUp()
-
test_compute_node_create()
-
test_compute_node_get_all()
-
test_compute_node_stat_prune()
-
test_compute_node_update()
-
class DbApiTestCase(methodName='runTest')
Bases: nova.test.TestCase
-
create_instances_with_args(**kwargs)
-
setUp()
-
test_bw_usage_calls()
-
test_dns_registration()
-
test_ec2_ids_not_found_are_printable()
-
test_fixed_ip_disassociate_all_by_timeout_multi_host()
-
test_fixed_ip_disassociate_all_by_timeout_single_host()
-
test_get_snap_mapping_non_admin()
-
test_get_vol_mapping_non_admin()
-
test_instance_fault_create()
Ensure we can create an instance fault
-
test_instance_fault_get_by_instance()
ensure we can retrieve an instance fault by instance UUID
-
test_instance_faults_get_by_instance_uuids_no_faults()
None should be returned when no faults exist
-
test_instance_get_all_by_filters()
-
test_instance_get_all_by_filters_deleted()
-
test_instance_get_all_by_filters_metadata()
-
test_instance_get_all_by_filters_paginate()
-
test_instance_get_all_by_filters_regex()
-
test_instance_get_all_by_filters_regex_unsupported_db()
Ensure that the ‘LIKE’ operator is used for unsupported dbs.
-
test_instance_get_all_by_filters_unicode_value()
-
test_instance_get_all_hung_in_rebooting()
-
test_instance_update_with_and_get_original()
-
test_instance_update_with_instance_uuid()
test instance_update() works when an instance UUID is passed
-
test_migration_get_unconfirmed_by_dest_compute()
-
test_network_create_safe()
-
test_network_create_with_duplicate_vlan()
-
test_network_delete_safe()
-
test_network_get_associated_fixed_ips()
-
class InstanceDestroyConstraints(methodName='runTest')
Bases: nova.test.TestCase
-
test_destroy_with_equal_any_constraint_met()
-
test_destroy_with_equal_any_constraint_not_met()
-
test_destroy_with_not_equal_constraint_met()
-
test_destroy_with_not_equal_constraint_not_met()
-
class SMVolumeDBApiTestCase(methodName='runTest')
Bases: nova.test.TestCase
-
setUp()
-
sm_flavor_create_raise_duplicate()
-
test_sm_backend_conf_create()
-
test_sm_backend_conf_create_raise_duplicate()
-
test_sm_backend_conf_delete()
-
test_sm_backend_conf_delete_nonexisting()
-
test_sm_backend_conf_get()
-
test_sm_backend_conf_get_by_sr()
-
test_sm_backend_conf_get_by_sr_raise_notfound()
-
test_sm_backend_conf_get_raise_notfound()
-
test_sm_backend_conf_update()
-
test_sm_backend_conf_update_raise_notfound()
-
test_sm_flavor_create()
-
test_sm_flavor_delete()
-
test_sm_flavor_delete_nonexisting()
-
test_sm_flavor_get()
-
test_sm_flavor_get_by_label()
-
test_sm_flavor_get_by_label_raise_notfound()
-
test_sm_flavor_get_raise_notfound()
-
test_sm_flavor_update()
-
test_sm_flavor_update_raise_notfound()
-
class TestIpAllocation(methodName='runTest')
Bases: nova.test.TestCase
-
create_fixed_ip(**params)
-
setUp()
-
test_fixed_ip_associate_fails_if_ip_in_use()
-
test_fixed_ip_associate_fails_if_ip_not_in_network()
-
test_fixed_ip_associate_succeeds()
-
test_fixed_ip_associate_succeeds_and_sets_network()