2026-01-23 13:11:15,398 - INFO - Domain Default found not creating 2026-01-23 13:11:15,575 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-57024648 not found, creating it 2026-01-23 13:11:16,022 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-57024648, ID : a2c43bb6-5693-4744-8535-0cb85dda9cf3 2026-01-23 13:11:17,775 - INFO - ================================================================================ 2026-01-23 13:11:17,775 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-01-23 13:11:18,035 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.254': '0'}} with 2026-01-23 13:11:18,035 - INFO - Initial checks done. Running the testcase now 2026-01-23 13:11:18,035 - INFO - 2026-01-23 13:11:18,035 - INFO - ================================================================================ 2026-01-23 13:11:18,035 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-01-23 13:11:18,035 - 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-01-23 13:11:18,324 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.254': '0'}} with 2026-01-23 13:11:18,324 - INFO - Initial checks done. Running the testcase now 2026-01-23 13:11:18,324 - INFO - 2026-01-23 13:11:18,646 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-57024648:ctest-vn4-92747984, 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-57024648:ctest-vn4-92747984, 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-57024648:ctest-vn4-92747984, 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-57024648:ctest-vn4-92747984, 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-01-23 13:11:19,159 - DEBUG - Response for create_network : {'network': {'id': '62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e', 'name': 'ctest-vn4-92747984', 'tenant_id': 'a2c43bb65693474485350cb85dda9cf3', 'project_id': 'a2c43bb65693474485350cb85dda9cf3', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-57024648', 'ctest-vn4-92747984'], 'port_security_enabled': True, 'description': ''}} 2026-01-23 13:11:19,348 - DEBUG - Response for create_subnet : {'subnet': {'id': '8103797f-4f59-4991-8ddd-66a27eca8a33', 'name': '', 'tenant_id': 'a2c43bb65693474485350cb85dda9cf3', 'network_id': '62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e', 'ip_version': 4, 'cidr': '136.77.19.192/26', 'allocation_pools': [{'start': '136.77.19.194', 'end': '136.77.19.254'}], 'gateway_ip': '136.77.19.193', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '136.77.19.194', 'tags': [], 'project_id': 'a2c43bb65693474485350cb85dda9cf3'}} 2026-01-23 13:11:19,557 - DEBUG - Response for create_subnet : {'subnet': {'id': '35b2b436-66af-4e02-bfe8-4d626df65778', 'name': '', 'tenant_id': 'a2c43bb65693474485350cb85dda9cf3', 'network_id': '62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e', 'ip_version': 6, 'cidr': '284a:a4c0:76e5:fe3e:f84:d53d::/96', 'allocation_pools': [{'start': '284a:a4c0:76e5:fe3e:f84:d53d:0:2', 'end': '284a:a4c0:76e5:fe3e:f84:d53d:ffff:fffe'}], 'gateway_ip': '284a:a4c0:76e5:fe3e:f84:d53d:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '284a:a4c0:76e5:fe3e:f84:d53d:0:2', 'tags': [], 'project_id': 'a2c43bb65693474485350cb85dda9cf3'}} 2026-01-23 13:11:19,581 - INFO - Created VN ctest-vn4-92747984 2026-01-23 13:11:19,635 - DEBUG - VN ctest-vn4-92747984 UUID is 62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:19,838 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e', 'name': 'ctest-vn4-92747984', 'tenant_id': 'a2c43bb65693474485350cb85dda9cf3', 'project_id': 'a2c43bb65693474485350cb85dda9cf3', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['8103797f-4f59-4991-8ddd-66a27eca8a33', '35b2b436-66af-4e02-bfe8-4d626df65778'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-57024648', 'ctest-vn4-92747984'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-57024648', 'ctest-policy1-13167413']], 'subnet_ipam': [{'subnet_cidr': '136.77.19.192/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '284a:a4c0:76e5:fe3e:f84:d53d::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-01-23 13:11:20,007 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-01-23 13:11:20,309 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-01-23 13:11:20,342 - DEBUG - Requesting: http://10.0.0.50:8082/domain/521e5d7c-a5cc-4328-a2e3-7fab4c7446f0 2026-01-23 13:11:20,354 - DEBUG - Requesting: http://10.0.0.50:8082/project/a2c43bb6-5693-4744-8535-0cb85dda9cf3 2026-01-23 13:11:20,425 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:20,435 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:20,444 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4dbda835-37a4-446b-90a8-c506a2e3ed63 2026-01-23 13:11:20,450 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4dbda835-37a4-446b-90a8-c506a2e3ed63 2026-01-23 13:11:20,456 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/4ed1cf50-fa90-40e2-9127-4760abd76014 2026-01-23 13:11:20,462 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-01-23 13:11:20,462 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:20,470 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4dbda835-37a4-446b-90a8-c506a2e3ed63 2026-01-23 13:11:20,483 - INFO - Verified VN network id 11 for VN 62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:20,483 - INFO - Verifications in API Server for VN ctest-vn4-92747984 passed 2026-01-23 13:11:20,483 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:20,492 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4dbda835-37a4-446b-90a8-c506a2e3ed63 2026-01-23 13:11:20,499 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4dbda835-37a4-446b-90a8-c506a2e3ed63 2026-01-23 13:11:20,505 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/4ed1cf50-fa90-40e2-9127-4760abd76014 2026-01-23 13:11:20,517 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-57024648:ctest-vn4-92747984', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-57024648', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '7107915288959075063', 'uuid-lslong': '13236909129735408238'}, 'enable': 'true', 'created': '2026-01-23T13:11:19', 'last-modified': '2026-01-23T13:11:19', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.713035'} 2026-01-23 13:11:20,524 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-01-23 13:11:20,524 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-92747984 passed 2026-01-23 13:11:20,524 - DEBUG - ====Verifying policy data for ctest-vn4-92747984 in API_Server ====== 2026-01-23 13:11:20,524 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-01-23 13:11:20,530 - DEBUG - Requesting: http://10.0.0.50:8082/domain/521e5d7c-a5cc-4328-a2e3-7fab4c7446f0 2026-01-23 13:11:20,540 - DEBUG - Requesting: http://10.0.0.50:8082/project/a2c43bb6-5693-4744-8535-0cb85dda9cf3 2026-01-23 13:11:20,612 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/62a4634b-c3f9-42f7-b7b2-f2b8aa010a6e 2026-01-23 13:11:20,621 - DEBUG - ==>Verifying data for policy with id: 5d5b89ae-74d2-4f51-a86a-797f76e1787a, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-57024648', 'ctest-policy1-13167413'] 2026-01-23 13:11:20,621 - INFO - VN ctest-vn4-92747984 Policy verification: verify_vn_policy_in_api_server, status: True 2026-01-23 13:11:20,621 - DEBUG - Verifying the vn in opserver 2026-01-23 13:11:20,621 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-57024648:ctest-vn4-92747984 virtual network link through opserver 10.0.0.50 2026-01-23 13:11:20,621 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-01-23 13:11:20,914 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-01-23 13:11:20,975 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-57024648:ctest-vn4-92747984', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-57024648:ctest-vn4-92747984?flat'} 2026-01-23 13:11:20,975 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-57024648:ctest-vn4-92747984 is found in opserver 2026-01-23 13:11:20,987 - DEBUG - Do not have enough data to verify VN in agent 2026-01-23 13:11:20,992 - DEBUG - VRF ids for VN ctest-vn4-92747984: {} 2026-01-23 13:11:20,992 - DEBUG - ====Verifying data for ctest-policy1-13167413 in API_Server ====== 2026-01-23 13:11:20,992 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-01-23 13:11:20,998 - DEBUG - Requesting: http://10.0.0.50:8082/domain/521e5d7c-a5cc-4328-a2e3-7fab4c7446f0 2026-01-23 13:11:21,009 - DEBUG - Requesting: http://10.0.0.50:8082/project/a2c43bb6-5693-4744-8535-0cb85dda9cf3 2026-01-23 13:11:21,077 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/5d5b89ae-74d2-4f51-a86a-797f76e1787a 2026-01-23 13:11:21,085 - INFO - Verified policy ctest-policy1-13167413 in API Server, Result: True 2026-01-23 13:11:21,085 - INFO - Done with setup and verification, moving onto test .. 2026-01-23 13:11:21,092 - INFO - Deleting VN ctest-vn4-92747984 2026-01-23 13:11:21,191 - DEBUG - Response for deleting network () 2026-01-23 13:11:21,191 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4dbda835-37a4-446b-90a8-c506a2e3ed63 2026-01-23 13:11:21,195 - DEBUG - Response Code: 404 2026-01-23 13:11:21,195 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-01-23 13:11:21,200 - DEBUG - Requesting: http://10.0.0.50:8082/domain/521e5d7c-a5cc-4328-a2e3-7fab4c7446f0 2026-01-23 13:11:21,256 - DEBUG - Requesting: http://10.0.0.50:8082/project/a2c43bb6-5693-4744-8535-0cb85dda9cf3 2026-01-23 13:11:21,324 - INFO - Validated that VN ctest-vn4-92747984 is not found in API Server 2026-01-23 13:11:21,335 - DEBUG - VN ctest-vn4-92747984 is not present in Agent 10.0.0.50 2026-01-23 13:11:21,336 - INFO - Validated that VN ctest-vn4-92747984 is not in any agent 2026-01-23 13:11:21,350 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-92747984 info 2026-01-23 13:11:21,374 - INFO - Deleted policy ctest-policy1-13167413 2026-01-23 13:11:21,538 - DEBUG - policy ctest-policy1-13167413 is not found in API Server 2026-01-23 13:11:21,792 - DEBUG - No XMPP flaps were noticed during the test
2026-01-23 13:11:21,792 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03]
2026-01-23 13:11:21,792 - INFO - -------------------------------------------------------------------------------- 2026-01-23 13:11:22,080 - DEBUG - No XMPP flaps were noticed during the test
2026-01-23 13:11:22,080 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2026-01-23 13:11:22,080 - INFO - -------------------------------------------------------------------------------- 2026-01-23 13:11:22,741 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-57024648, ID : a2c43bb6-5693-4744-8535-0cb85dda9cf3