2026-05-29 12:56:59,332 - INFO - Domain Default found not creating 2026-05-29 12:56:59,496 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-53536967 not found, creating it 2026-05-29 12:56:59,949 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-53536967, ID : 042a0b90-d28e-4803-a407-5175ab706c09 2026-05-29 12:57:01,495 - INFO - ================================================================================ 2026-05-29 12:57:01,495 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-05-29 12:57:01,752 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2026-05-29 12:57:01,752 - INFO - Initial checks done. Running the testcase now 2026-05-29 12:57:01,752 - INFO - 2026-05-29 12:57:01,752 - INFO - ================================================================================ 2026-05-29 12:57:01,752 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-05-29 12:57:01,753 - INFO - TEST DESCRIPTION : This tests the following scenarios. 1. Test to validate that policy removal will fail when it referenced with VN. 2. validate vn_policy data in api-s against quantum-vn data, when created and unbind policy from VN thru quantum APIs. 3. validate policy data in api-s against quantum-policy data, when created and deleted thru quantum APIs. 2026-05-29 12:57:02,047 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2026-05-29 12:57:02,047 - INFO - Initial checks done. Running the testcase now 2026-05-29 12:57:02,047 - INFO - 2026-05-29 12:57:02,420 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636, security_group = None, network_policy = None, subnet_list = []], src_ports = [start_port = -1, end_port = -1], application = [], dst_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636, security_group = None, network_policy = None, subnet_list = []], dst_ports = [start_port = -1, end_port = -1], action_list = simple_action = pass, gateway_name = None, apply_service = [], service_properties = None, mirror_to = None, assign_routing_instance = None, log = False, alert = False, qos_action = None, host_based_service = False, ethertype = None, created = None, last_modified = None, description = None, rule_sequence = None, rule_uuid = None, direction = <>, protocol = 58, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636, security_group = None, network_policy = None, subnet_list = []], src_ports = [start_port = -1, end_port = -1], application = [], dst_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636, security_group = None, network_policy = None, subnet_list = []], dst_ports = [start_port = -1, end_port = -1], action_list = simple_action = pass, gateway_name = None, apply_service = [], service_properties = None, mirror_to = None, assign_routing_instance = None, log = False, alert = False, qos_action = None, host_based_service = False, ethertype = None, created = None, last_modified = None, description = None] 2026-05-29 12:57:02,947 - DEBUG - Response for create_network : {'network': {'id': '36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8', 'name': 'ctest-vn4-40471636', 'tenant_id': '042a0b90d28e4803a4075175ab706c09', 'project_id': '042a0b90d28e4803a4075175ab706c09', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-53536967', 'ctest-vn4-40471636'], 'port_security_enabled': True, 'description': ''}} 2026-05-29 12:57:03,144 - DEBUG - Response for create_subnet : {'subnet': {'id': '173026fc-03d4-4147-9fc9-87400ff6eb44', 'name': '', 'tenant_id': '042a0b90d28e4803a4075175ab706c09', 'network_id': '36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8', 'ip_version': 4, 'cidr': '71.228.37.64/26', 'allocation_pools': [{'start': '71.228.37.66', 'end': '71.228.37.126'}], 'gateway_ip': '71.228.37.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '71.228.37.66', 'tags': [], 'project_id': '042a0b90d28e4803a4075175ab706c09'}} 2026-05-29 12:57:03,310 - DEBUG - Response for create_subnet : {'subnet': {'id': '9df11791-6ce2-447f-a694-37017c58587b', 'name': '', 'tenant_id': '042a0b90d28e4803a4075175ab706c09', 'network_id': '36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8', 'ip_version': 6, 'cidr': '3067:c921:dc3:6c14:3752:a238::/96', 'allocation_pools': [{'start': '3067:c921:dc3:6c14:3752:a238:0:2', 'end': '3067:c921:dc3:6c14:3752:a238:ffff:fffe'}], 'gateway_ip': '3067:c921:dc3:6c14:3752:a238:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '3067:c921:dc3:6c14:3752:a238:0:2', 'tags': [], 'project_id': '042a0b90d28e4803a4075175ab706c09'}} 2026-05-29 12:57:03,329 - INFO - Created VN ctest-vn4-40471636 2026-05-29 12:57:03,379 - DEBUG - VN ctest-vn4-40471636 UUID is 36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:03,588 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8', 'name': 'ctest-vn4-40471636', 'tenant_id': '042a0b90d28e4803a4075175ab706c09', 'project_id': '042a0b90d28e4803a4075175ab706c09', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['173026fc-03d4-4147-9fc9-87400ff6eb44', '9df11791-6ce2-447f-a694-37017c58587b'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-53536967', 'ctest-vn4-40471636'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-53536967', 'ctest-policy1-28249105']], 'subnet_ipam': [{'subnet_cidr': '71.228.37.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '3067:c921:dc3:6c14:3752:a238::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-05-29 12:57:03,759 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-29 12:57:04,088 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-29 12:57:04,128 - DEBUG - Requesting: http://10.0.0.50:8082/domain/34a5ab6b-810b-4978-88bd-37e1c12509ed 2026-05-29 12:57:04,142 - DEBUG - Requesting: http://10.0.0.50:8082/project/042a0b90-d28e-4803-a407-5175ab706c09 2026-05-29 12:57:04,228 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:04,242 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:04,255 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/fb57115e-05cd-4499-9589-bcd4fc3bf833 2026-05-29 12:57:04,264 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/fb57115e-05cd-4499-9589-bcd4fc3bf833 2026-05-29 12:57:04,273 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/8023e7e5-e264-4bb7-95c1-64d853fd9934 2026-05-29 12:57:04,280 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-05-29 12:57:04,280 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:04,290 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/fb57115e-05cd-4499-9589-bcd4fc3bf833 2026-05-29 12:57:04,308 - INFO - Verified VN network id 11 for VN 36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:04,308 - INFO - Verifications in API Server for VN ctest-vn4-40471636 passed 2026-05-29 12:57:04,308 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:04,321 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/fb57115e-05cd-4499-9589-bcd4fc3bf833 2026-05-29 12:57:04,329 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/fb57115e-05cd-4499-9589-bcd4fc3bf833 2026-05-29 12:57:04,336 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/8023e7e5-e264-4bb7-95c1-64d853fd9934 2026-05-29 12:57:04,349 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-53536967', 'owner-access': '7', 'group': 'member', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '3954976423930187319', 'uuid-lslong': '10244829663393665272'}, 'enable': 'true', 'created': '2026-05-29T12:57:02', 'last-modified': '2026-05-29T12:57:03', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.786392'} 2026-05-29 12:57:04,355 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-05-29 12:57:04,355 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-40471636 passed 2026-05-29 12:57:04,355 - DEBUG - ====Verifying policy data for ctest-vn4-40471636 in API_Server ====== 2026-05-29 12:57:04,355 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-29 12:57:04,360 - DEBUG - Requesting: http://10.0.0.50:8082/domain/34a5ab6b-810b-4978-88bd-37e1c12509ed 2026-05-29 12:57:04,372 - DEBUG - Requesting: http://10.0.0.50:8082/project/042a0b90-d28e-4803-a407-5175ab706c09 2026-05-29 12:57:04,441 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/36e2e61a-6b67-4e37-8e2c-f24ca6f6d0f8 2026-05-29 12:57:04,451 - DEBUG - ==>Verifying data for policy with id: 04c0afbe-e5ef-4546-b0a7-782913fc4fa5, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-53536967', 'ctest-policy1-28249105'] 2026-05-29 12:57:04,451 - INFO - VN ctest-vn4-40471636 Policy verification: verify_vn_policy_in_api_server, status: True 2026-05-29 12:57:04,451 - DEBUG - Verifying the vn in opserver 2026-05-29 12:57:04,451 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636 virtual network link through opserver 10.0.0.50 2026-05-29 12:57:04,451 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-05-29 12:57:04,742 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-05-29 12:57:04,813 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636?flat'} 2026-05-29 12:57:04,813 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-53536967:ctest-vn4-40471636 is found in opserver 2026-05-29 12:57:04,822 - DEBUG - Do not have enough data to verify VN in agent 2026-05-29 12:57:04,827 - DEBUG - VRF ids for VN ctest-vn4-40471636: {} 2026-05-29 12:57:04,827 - DEBUG - ====Verifying data for ctest-policy1-28249105 in API_Server ====== 2026-05-29 12:57:04,827 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-29 12:57:04,833 - DEBUG - Requesting: http://10.0.0.50:8082/domain/34a5ab6b-810b-4978-88bd-37e1c12509ed 2026-05-29 12:57:04,844 - DEBUG - Requesting: http://10.0.0.50:8082/project/042a0b90-d28e-4803-a407-5175ab706c09 2026-05-29 12:57:04,920 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/04c0afbe-e5ef-4546-b0a7-782913fc4fa5 2026-05-29 12:57:04,930 - INFO - Verified policy ctest-policy1-28249105 in API Server, Result: True 2026-05-29 12:57:04,930 - INFO - Done with setup and verification, moving onto test .. 2026-05-29 12:57:04,939 - INFO - Deleting VN ctest-vn4-40471636 2026-05-29 12:57:05,057 - DEBUG - Response for deleting network () 2026-05-29 12:57:05,057 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/fb57115e-05cd-4499-9589-bcd4fc3bf833 2026-05-29 12:57:05,062 - DEBUG - Response Code: 404 2026-05-29 12:57:05,062 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-29 12:57:05,068 - DEBUG - Requesting: http://10.0.0.50:8082/domain/34a5ab6b-810b-4978-88bd-37e1c12509ed 2026-05-29 12:57:05,124 - DEBUG - Requesting: http://10.0.0.50:8082/project/042a0b90-d28e-4803-a407-5175ab706c09 2026-05-29 12:57:05,195 - INFO - Validated that VN ctest-vn4-40471636 is not found in API Server 2026-05-29 12:57:05,205 - DEBUG - VN ctest-vn4-40471636 is not present in Agent 10.0.0.50 2026-05-29 12:57:05,205 - INFO - Validated that VN ctest-vn4-40471636 is not in any agent 2026-05-29 12:57:05,219 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-40471636 info 2026-05-29 12:57:05,244 - INFO - Deleted policy ctest-policy1-28249105 2026-05-29 12:57:05,403 - DEBUG - policy ctest-policy1-28249105 is not found in API Server 2026-05-29 12:57:05,655 - DEBUG - No XMPP flaps were noticed during the test
2026-05-29 12:57:05,655 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2026-05-29 12:57:05,655 - INFO - -------------------------------------------------------------------------------- 2026-05-29 12:57:05,943 - DEBUG - No XMPP flaps were noticed during the test
2026-05-29 12:57:05,943 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2026-05-29 12:57:05,943 - INFO - -------------------------------------------------------------------------------- 2026-05-29 12:57:06,653 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-53536967, ID : 042a0b90-d28e-4803-a407-5175ab706c09