2026-04-24 14:15:27,724 - INFO - Domain Default found not creating 2026-04-24 14:15:27,906 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-17309557 not found, creating it 2026-04-24 14:15:28,385 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-17309557, ID : e410e647-b7b2-4927-bd5a-eb29113c0e7c 2026-04-24 14:15:29,959 - INFO - ================================================================================ 2026-04-24 14:15:29,960 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-04-24 14:15:30,221 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.17': '0'}} with 2026-04-24 14:15:30,221 - INFO - Initial checks done. Running the testcase now 2026-04-24 14:15:30,221 - INFO - 2026-04-24 14:15:30,221 - INFO - ================================================================================ 2026-04-24 14:15:30,221 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-04-24 14:15:30,221 - 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-04-24 14:15:30,512 - DEBUG - Nothing to compare xmpp stats {'10.0.0.249': {'10.20.0.17': '0'}} with 2026-04-24 14:15:30,512 - INFO - Initial checks done. Running the testcase now 2026-04-24 14:15:30,512 - INFO - 2026-04-24 14:15:30,889 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-17309557:ctest-vn4-41453100, 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-17309557:ctest-vn4-41453100, 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-17309557:ctest-vn4-41453100, 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-17309557:ctest-vn4-41453100, 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-04-24 14:15:31,431 - DEBUG - Response for create_network : {'network': {'id': '0354af1e-5dba-4f63-b653-cb992a097163', 'name': 'ctest-vn4-41453100', 'tenant_id': 'e410e647b7b24927bd5aeb29113c0e7c', 'project_id': 'e410e647b7b24927bd5aeb29113c0e7c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-17309557', 'ctest-vn4-41453100'], 'port_security_enabled': True, 'description': ''}} 2026-04-24 14:15:31,651 - DEBUG - Response for create_subnet : {'subnet': {'id': 'f95b0ccd-59d1-4d87-a32e-588abb3b3e1e', 'name': '', 'tenant_id': 'e410e647b7b24927bd5aeb29113c0e7c', 'network_id': '0354af1e-5dba-4f63-b653-cb992a097163', 'ip_version': 4, 'cidr': '149.187.242.128/26', 'allocation_pools': [{'start': '149.187.242.130', 'end': '149.187.242.190'}], 'gateway_ip': '149.187.242.129', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '149.187.242.130', 'tags': [], 'project_id': 'e410e647b7b24927bd5aeb29113c0e7c'}} 2026-04-24 14:15:31,810 - DEBUG - Response for create_subnet : {'subnet': {'id': '392f0fcd-ad80-49dc-be0d-86c84e760860', 'name': '', 'tenant_id': 'e410e647b7b24927bd5aeb29113c0e7c', 'network_id': '0354af1e-5dba-4f63-b653-cb992a097163', 'ip_version': 6, 'cidr': '34f6:8e02:fe27:55ae:4425:e097::/96', 'allocation_pools': [{'start': '34f6:8e02:fe27:55ae:4425:e097:0:2', 'end': '34f6:8e02:fe27:55ae:4425:e097:ffff:fffe'}], 'gateway_ip': '34f6:8e02:fe27:55ae:4425:e097:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '34f6:8e02:fe27:55ae:4425:e097:0:2', 'tags': [], 'project_id': 'e410e647b7b24927bd5aeb29113c0e7c'}} 2026-04-24 14:15:31,833 - INFO - Created VN ctest-vn4-41453100 2026-04-24 14:15:31,887 - DEBUG - VN ctest-vn4-41453100 UUID is 0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,126 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '0354af1e-5dba-4f63-b653-cb992a097163', 'name': 'ctest-vn4-41453100', 'tenant_id': 'e410e647b7b24927bd5aeb29113c0e7c', 'project_id': 'e410e647b7b24927bd5aeb29113c0e7c', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['f95b0ccd-59d1-4d87-a32e-588abb3b3e1e', '392f0fcd-ad80-49dc-be0d-86c84e760860'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-17309557', 'ctest-vn4-41453100'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-17309557', 'ctest-policy1-77345030']], 'subnet_ipam': [{'subnet_cidr': '149.187.242.128/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '34f6:8e02:fe27:55ae:4425:e097::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-04-24 14:15:32,291 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-04-24 14:15:32,594 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-04-24 14:15:32,632 - DEBUG - Requesting: http://10.0.0.249:8082/domain/79c65c63-69d7-41bc-97be-09914138ab11 2026-04-24 14:15:32,647 - DEBUG - Requesting: http://10.0.0.249:8082/project/e410e647-b7b2-4927-bd5a-eb29113c0e7c 2026-04-24 14:15:32,722 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,736 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,746 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/92e48e5e-4b15-4177-ae73-aa254436a822 2026-04-24 14:15:32,754 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/92e48e5e-4b15-4177-ae73-aa254436a822 2026-04-24 14:15:32,761 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/13978381-4cb6-422a-b972-2a1217ab9848 2026-04-24 14:15:32,768 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-04-24 14:15:32,768 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,778 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/92e48e5e-4b15-4177-ae73-aa254436a822 2026-04-24 14:15:32,794 - INFO - Verified VN network id 11 for VN 0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,794 - INFO - Verifications in API Server for VN ctest-vn4-41453100 passed 2026-04-24 14:15:32,794 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,803 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/92e48e5e-4b15-4177-ae73-aa254436a822 2026-04-24 14:15:32,811 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/92e48e5e-4b15-4177-ae73-aa254436a822 2026-04-24 14:15:32,819 - DEBUG - Requesting: http://10.0.0.249:8082/route-target/13978381-4cb6-422a-b972-2a1217ab9848 2026-04-24 14:15:32,831 - DEBUG - Control-node 10.0.0.249 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-17309557:ctest-vn4-41453100', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-17309557', 'owner-access': '7', 'group': 'reader', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '240009225113849699', 'uuid-lslong': '13138068396665565539'}, 'enable': 'true', 'created': '2026-04-24T14:15:31', 'last-modified': '2026-04-24T14:15:32', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.746198'} 2026-04-24 14:15:32,837 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-04-24 14:15:32,837 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-41453100 passed 2026-04-24 14:15:32,837 - DEBUG - ====Verifying policy data for ctest-vn4-41453100 in API_Server ====== 2026-04-24 14:15:32,837 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-04-24 14:15:32,844 - DEBUG - Requesting: http://10.0.0.249:8082/domain/79c65c63-69d7-41bc-97be-09914138ab11 2026-04-24 14:15:32,858 - DEBUG - Requesting: http://10.0.0.249:8082/project/e410e647-b7b2-4927-bd5a-eb29113c0e7c 2026-04-24 14:15:32,934 - DEBUG - Requesting: http://10.0.0.249:8082/virtual-network/0354af1e-5dba-4f63-b653-cb992a097163 2026-04-24 14:15:32,945 - DEBUG - ==>Verifying data for policy with id: 03ec134a-7572-4e0e-a867-d3e90493a1a7, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-17309557', 'ctest-policy1-77345030'] 2026-04-24 14:15:32,945 - INFO - VN ctest-vn4-41453100 Policy verification: verify_vn_policy_in_api_server, status: True 2026-04-24 14:15:32,945 - DEBUG - Verifying the vn in opserver 2026-04-24 14:15:32,945 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-17309557:ctest-vn4-41453100 virtual network link through opserver 10.0.0.249 2026-04-24 14:15:32,946 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2026-04-24 14:15:33,248 - DEBUG - Requesting: http://10.0.0.249:8081/analytics/uves/virtual-networks 2026-04-24 14:15:33,315 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-17309557:ctest-vn4-41453100', 'href': 'http://10.0.0.249:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-17309557:ctest-vn4-41453100?flat'} 2026-04-24 14:15:33,315 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-17309557:ctest-vn4-41453100 is found in opserver 2026-04-24 14:15:33,326 - DEBUG - Do not have enough data to verify VN in agent 2026-04-24 14:15:33,331 - DEBUG - VRF ids for VN ctest-vn4-41453100: {} 2026-04-24 14:15:33,331 - DEBUG - ====Verifying data for ctest-policy1-77345030 in API_Server ====== 2026-04-24 14:15:33,331 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-04-24 14:15:33,337 - DEBUG - Requesting: http://10.0.0.249:8082/domain/79c65c63-69d7-41bc-97be-09914138ab11 2026-04-24 14:15:33,350 - DEBUG - Requesting: http://10.0.0.249:8082/project/e410e647-b7b2-4927-bd5a-eb29113c0e7c 2026-04-24 14:15:33,429 - DEBUG - Requesting: http://10.0.0.249:8082/network-policy/03ec134a-7572-4e0e-a867-d3e90493a1a7 2026-04-24 14:15:33,440 - INFO - Verified policy ctest-policy1-77345030 in API Server, Result: True 2026-04-24 14:15:33,440 - INFO - Done with setup and verification, moving onto test .. 2026-04-24 14:15:33,450 - INFO - Deleting VN ctest-vn4-41453100 2026-04-24 14:15:33,586 - DEBUG - Response for deleting network () 2026-04-24 14:15:33,586 - DEBUG - Requesting: http://10.0.0.249:8082/routing-instance/92e48e5e-4b15-4177-ae73-aa254436a822 2026-04-24 14:15:33,592 - DEBUG - Response Code: 404 2026-04-24 14:15:33,592 - DEBUG - Requesting: http://10.0.0.249:8082/domains 2026-04-24 14:15:33,599 - DEBUG - Requesting: http://10.0.0.249:8082/domain/79c65c63-69d7-41bc-97be-09914138ab11 2026-04-24 14:15:33,652 - DEBUG - Requesting: http://10.0.0.249:8082/project/e410e647-b7b2-4927-bd5a-eb29113c0e7c 2026-04-24 14:15:33,724 - INFO - Validated that VN ctest-vn4-41453100 is not found in API Server 2026-04-24 14:15:33,733 - DEBUG - VN ctest-vn4-41453100 is not present in Agent 10.0.0.249 2026-04-24 14:15:33,733 - INFO - Validated that VN ctest-vn4-41453100 is not in any agent 2026-04-24 14:15:33,747 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-41453100 info 2026-04-24 14:15:33,782 - INFO - Deleted policy ctest-policy1-77345030 2026-04-24 14:15:33,959 - DEBUG - policy ctest-policy1-77345030 is not found in API Server 2026-04-24 14:15:34,216 - DEBUG - No XMPP flaps were noticed during the test
2026-04-24 14:15:34,216 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2026-04-24 14:15:34,216 - INFO - -------------------------------------------------------------------------------- 2026-04-24 14:15:34,519 - DEBUG - No XMPP flaps were noticed during the test
2026-04-24 14:15:34,519 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2026-04-24 14:15:34,519 - INFO - -------------------------------------------------------------------------------- 2026-04-24 14:15:35,248 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-17309557, ID : e410e647-b7b2-4927-bd5a-eb29113c0e7c