2026-05-20 14:34:34,308 - INFO - Domain Default found not creating 2026-05-20 14:34:34,520 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-98645786 not found, creating it 2026-05-20 14:34:35,016 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-98645786, ID : 158d9eaf-e71a-475c-a473-31118b1087b7 2026-05-20 14:34:36,681 - INFO - ================================================================================ 2026-05-20 14:34:36,681 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-05-20 14:34:36,936 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.254': '0'}} with 2026-05-20 14:34:36,936 - INFO - Initial checks done. Running the testcase now 2026-05-20 14:34:36,936 - INFO - 2026-05-20 14:34:36,936 - INFO - ================================================================================ 2026-05-20 14:34:36,936 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-05-20 14:34:36,936 - 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-20 14:34:37,229 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.254': '0'}} with 2026-05-20 14:34:37,229 - INFO - Initial checks done. Running the testcase now 2026-05-20 14:34:37,229 - INFO - 2026-05-20 14:34:37,606 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-98645786:ctest-vn4-86342367, 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-98645786:ctest-vn4-86342367, 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-98645786:ctest-vn4-86342367, 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-98645786:ctest-vn4-86342367, 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-20 14:34:38,151 - DEBUG - Response for create_network : {'network': {'id': '04be2d59-f88c-4a8b-8bfe-f94d665e9392', 'name': 'ctest-vn4-86342367', 'tenant_id': '158d9eafe71a475ca47331118b1087b7', 'project_id': '158d9eafe71a475ca47331118b1087b7', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-98645786', 'ctest-vn4-86342367'], 'port_security_enabled': True, 'description': ''}} 2026-05-20 14:34:38,319 - DEBUG - Response for create_subnet : {'subnet': {'id': '74ef40f9-cf39-49a1-a9c2-8a21ecea75f7', 'name': '', 'tenant_id': '158d9eafe71a475ca47331118b1087b7', 'network_id': '04be2d59-f88c-4a8b-8bfe-f94d665e9392', 'ip_version': 4, 'cidr': '43.99.79.128/26', 'allocation_pools': [{'start': '43.99.79.130', 'end': '43.99.79.190'}], 'gateway_ip': '43.99.79.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '43.99.79.130', 'tags': [], 'project_id': '158d9eafe71a475ca47331118b1087b7'}} 2026-05-20 14:34:38,478 - DEBUG - Response for create_subnet : {'subnet': {'id': '8261f85c-1415-4155-afee-9e2ddf4015d8', 'name': '', 'tenant_id': '158d9eafe71a475ca47331118b1087b7', 'network_id': '04be2d59-f88c-4a8b-8bfe-f94d665e9392', 'ip_version': 6, 'cidr': '380b:dc61:ed39:4db8:cc80:827::/96', 'allocation_pools': [{'start': '380b:dc61:ed39:4db8:cc80:827:0:2', 'end': '380b:dc61:ed39:4db8:cc80:827:ffff:fffe'}], 'gateway_ip': '380b:dc61:ed39:4db8:cc80:827:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '380b:dc61:ed39:4db8:cc80:827:0:2', 'tags': [], 'project_id': '158d9eafe71a475ca47331118b1087b7'}} 2026-05-20 14:34:38,503 - INFO - Created VN ctest-vn4-86342367 2026-05-20 14:34:38,558 - DEBUG - VN ctest-vn4-86342367 UUID is 04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:38,800 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '04be2d59-f88c-4a8b-8bfe-f94d665e9392', 'name': 'ctest-vn4-86342367', 'tenant_id': '158d9eafe71a475ca47331118b1087b7', 'project_id': '158d9eafe71a475ca47331118b1087b7', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['74ef40f9-cf39-49a1-a9c2-8a21ecea75f7', '8261f85c-1415-4155-afee-9e2ddf4015d8'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-98645786', 'ctest-vn4-86342367'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-98645786', 'ctest-policy1-76514572']], 'subnet_ipam': [{'subnet_cidr': '43.99.79.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '380b:dc61:ed39:4db8:cc80:827::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-05-20 14:34:38,954 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-20 14:34:39,258 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-20 14:34:39,293 - DEBUG - Requesting: http://10.0.0.50:8082/domain/69153c15-03f5-4428-b130-bd33acb6977f 2026-05-20 14:34:39,308 - DEBUG - Requesting: http://10.0.0.50:8082/project/158d9eaf-e71a-475c-a473-31118b1087b7 2026-05-20 14:34:39,382 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:39,396 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:39,409 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/669d7579-7834-4f55-bd25-4be31df083f9 2026-05-20 14:34:39,419 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/669d7579-7834-4f55-bd25-4be31df083f9 2026-05-20 14:34:39,427 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/513cdbe0-fad2-4091-9eef-db23c1777d5b 2026-05-20 14:34:39,436 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-05-20 14:34:39,436 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:39,448 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/669d7579-7834-4f55-bd25-4be31df083f9 2026-05-20 14:34:39,467 - INFO - Verified VN network id 11 for VN 04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:39,467 - INFO - Verifications in API Server for VN ctest-vn4-86342367 passed 2026-05-20 14:34:39,467 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:39,481 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/669d7579-7834-4f55-bd25-4be31df083f9 2026-05-20 14:34:39,490 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/669d7579-7834-4f55-bd25-4be31df083f9 2026-05-20 14:34:39,498 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/513cdbe0-fad2-4091-9eef-db23c1777d5b 2026-05-20 14:34:39,512 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-98645786:ctest-vn4-86342367', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-98645786', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '341760486172019339', 'uuid-lslong': '10087774326181761938'}, 'enable': 'true', 'created': '2026-05-20T14:34:38', 'last-modified': '2026-05-20T14:34:38', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.749355'} 2026-05-20 14:34:39,518 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-05-20 14:34:39,519 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-86342367 passed 2026-05-20 14:34:39,519 - DEBUG - ====Verifying policy data for ctest-vn4-86342367 in API_Server ====== 2026-05-20 14:34:39,519 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-20 14:34:39,525 - DEBUG - Requesting: http://10.0.0.50:8082/domain/69153c15-03f5-4428-b130-bd33acb6977f 2026-05-20 14:34:39,537 - DEBUG - Requesting: http://10.0.0.50:8082/project/158d9eaf-e71a-475c-a473-31118b1087b7 2026-05-20 14:34:39,615 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/04be2d59-f88c-4a8b-8bfe-f94d665e9392 2026-05-20 14:34:39,629 - DEBUG - ==>Verifying data for policy with id: 619685a9-d505-4f38-8101-04ed096288b9, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-98645786', 'ctest-policy1-76514572'] 2026-05-20 14:34:39,629 - INFO - VN ctest-vn4-86342367 Policy verification: verify_vn_policy_in_api_server, status: True 2026-05-20 14:34:39,629 - DEBUG - Verifying the vn in opserver 2026-05-20 14:34:39,629 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-98645786:ctest-vn4-86342367 virtual network link through opserver 10.0.0.50 2026-05-20 14:34:39,629 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-05-20 14:34:39,934 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-05-20 14:34:40,008 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-98645786:ctest-vn4-86342367', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-98645786:ctest-vn4-86342367?flat'} 2026-05-20 14:34:40,008 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-98645786:ctest-vn4-86342367 is found in opserver 2026-05-20 14:34:40,020 - DEBUG - Do not have enough data to verify VN in agent 2026-05-20 14:34:40,025 - DEBUG - VRF ids for VN ctest-vn4-86342367: {} 2026-05-20 14:34:40,025 - DEBUG - ====Verifying data for ctest-policy1-76514572 in API_Server ====== 2026-05-20 14:34:40,026 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-20 14:34:40,033 - DEBUG - Requesting: http://10.0.0.50:8082/domain/69153c15-03f5-4428-b130-bd33acb6977f 2026-05-20 14:34:40,049 - DEBUG - Requesting: http://10.0.0.50:8082/project/158d9eaf-e71a-475c-a473-31118b1087b7 2026-05-20 14:34:40,124 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/619685a9-d505-4f38-8101-04ed096288b9 2026-05-20 14:34:40,137 - INFO - Verified policy ctest-policy1-76514572 in API Server, Result: True 2026-05-20 14:34:40,137 - INFO - Done with setup and verification, moving onto test .. 2026-05-20 14:34:40,147 - INFO - Deleting VN ctest-vn4-86342367 2026-05-20 14:34:40,282 - DEBUG - Response for deleting network () 2026-05-20 14:34:40,282 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/669d7579-7834-4f55-bd25-4be31df083f9 2026-05-20 14:34:40,288 - DEBUG - Response Code: 404 2026-05-20 14:34:40,289 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-05-20 14:34:40,295 - DEBUG - Requesting: http://10.0.0.50:8082/domain/69153c15-03f5-4428-b130-bd33acb6977f 2026-05-20 14:34:40,349 - DEBUG - Requesting: http://10.0.0.50:8082/project/158d9eaf-e71a-475c-a473-31118b1087b7 2026-05-20 14:34:40,427 - INFO - Validated that VN ctest-vn4-86342367 is not found in API Server 2026-05-20 14:34:40,443 - DEBUG - VN ctest-vn4-86342367 is not present in Agent 10.0.0.50 2026-05-20 14:34:40,443 - INFO - Validated that VN ctest-vn4-86342367 is not in any agent 2026-05-20 14:34:40,458 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-86342367 info 2026-05-20 14:34:40,495 - INFO - Deleted policy ctest-policy1-76514572 2026-05-20 14:34:40,669 - DEBUG - policy ctest-policy1-76514572 is not found in API Server 2026-05-20 14:34:40,923 - DEBUG - No XMPP flaps were noticed during the test
2026-05-20 14:34:40,923 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2026-05-20 14:34:40,923 - INFO - -------------------------------------------------------------------------------- 2026-05-20 14:34:41,227 - DEBUG - No XMPP flaps were noticed during the test
2026-05-20 14:34:41,227 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2026-05-20 14:34:41,227 - INFO - -------------------------------------------------------------------------------- 2026-05-20 14:34:41,981 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-98645786, ID : 158d9eaf-e71a-475c-a473-31118b1087b7