2026-09-17 20:39:41,538 - INFO - Domain Default found not creating 2026-09-17 20:39:41,705 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-21473979 not found, creating it 2026-09-17 20:39:42,183 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-21473979, ID : b7189ee0-7dc0-4054-ae5c-24943e835c20 2026-09-17 20:39:43,784 - INFO - ================================================================================ 2026-09-17 20:39:43,784 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-09-17 20:39:44,044 - DEBUG - Nothing to compare xmpp stats {'10.0.0.250': {'10.20.0.17': '0'}} with 2026-09-17 20:39:44,044 - INFO - Initial checks done. Running the testcase now 2026-09-17 20:39:44,044 - INFO - 2026-09-17 20:39:44,044 - INFO - ================================================================================ 2026-09-17 20:39:44,044 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-09-17 20:39:44,044 - 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-09-17 20:39:44,338 - DEBUG - Nothing to compare xmpp stats {'10.0.0.250': {'10.20.0.17': '0'}} with 2026-09-17 20:39:44,338 - INFO - Initial checks done. Running the testcase now 2026-09-17 20:39:44,338 - INFO - 2026-09-17 20:39:44,725 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-21473979:ctest-vn4-64763320, 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-21473979:ctest-vn4-64763320, 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-21473979:ctest-vn4-64763320, 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-21473979:ctest-vn4-64763320, 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-09-17 20:39:45,248 - DEBUG - Response for create_network : {'network': {'id': 'a07afc42-1a25-4cb7-bb10-65fd6cc9a8df', 'name': 'ctest-vn4-64763320', 'tenant_id': 'b7189ee07dc04054ae5c24943e835c20', 'project_id': 'b7189ee07dc04054ae5c24943e835c20', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'tags': [], 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-21473979', 'ctest-vn4-64763320'], 'port_security_enabled': True, 'description': ''}} 2026-09-17 20:39:45,412 - DEBUG - Response for create_subnet : {'subnet': {'id': '65a9bd2d-4184-48fe-a02f-ce0361268404', 'name': '', 'tenant_id': 'b7189ee07dc04054ae5c24943e835c20', 'network_id': 'a07afc42-1a25-4cb7-bb10-65fd6cc9a8df', 'ip_version': 4, 'cidr': '126.114.12.64/26', 'allocation_pools': [{'start': '126.114.12.66', 'end': '126.114.12.126'}], 'gateway_ip': '126.114.12.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '126.114.12.66', 'tags': [], 'project_id': 'b7189ee07dc04054ae5c24943e835c20'}} 2026-09-17 20:39:45,608 - DEBUG - Response for create_subnet : {'subnet': {'id': 'a2077927-2367-478f-a2a7-ce7eec6c64d0', 'name': '', 'tenant_id': 'b7189ee07dc04054ae5c24943e835c20', 'network_id': 'a07afc42-1a25-4cb7-bb10-65fd6cc9a8df', 'ip_version': 6, 'cidr': '319f:6ff8:9e7e:d80a:b7f0:6b8c::/96', 'allocation_pools': [{'start': '319f:6ff8:9e7e:d80a:b7f0:6b8c:0:2', 'end': '319f:6ff8:9e7e:d80a:b7f0:6b8c:ffff:fffe'}], 'gateway_ip': '319f:6ff8:9e7e:d80a:b7f0:6b8c:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '319f:6ff8:9e7e:d80a:b7f0:6b8c:0:2', 'tags': [], 'project_id': 'b7189ee07dc04054ae5c24943e835c20'}} 2026-09-17 20:39:45,633 - INFO - Created VN ctest-vn4-64763320 2026-09-17 20:39:45,686 - DEBUG - VN ctest-vn4-64763320 UUID is a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:45,887 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': 'a07afc42-1a25-4cb7-bb10-65fd6cc9a8df', 'name': 'ctest-vn4-64763320', 'tenant_id': 'b7189ee07dc04054ae5c24943e835c20', 'project_id': 'b7189ee07dc04054ae5c24943e835c20', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'tags': [], 'subnets': ['65a9bd2d-4184-48fe-a02f-ce0361268404', 'a2077927-2367-478f-a2a7-ce7eec6c64d0'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-21473979', 'ctest-vn4-64763320'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-21473979', 'ctest-policy1-65550771']], 'subnet_ipam': [{'subnet_cidr': '126.114.12.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '319f:6ff8:9e7e:d80a:b7f0:6b8c::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-09-17 20:39:46,054 - DEBUG - Requesting: http://10.0.0.250:8082/domains 2026-09-17 20:39:46,375 - DEBUG - Requesting: http://10.0.0.250:8082/domains 2026-09-17 20:39:46,402 - DEBUG - Requesting: http://10.0.0.250:8082/domain/a2e54ebb-b2d3-4607-b2a9-b4dd4b8880ff 2026-09-17 20:39:46,415 - DEBUG - Requesting: http://10.0.0.250:8082/project/b7189ee0-7dc0-4054-ae5c-24943e835c20 2026-09-17 20:39:46,496 - DEBUG - Requesting: http://10.0.0.250:8082/virtual-network/a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:46,509 - DEBUG - Requesting: http://10.0.0.250:8082/virtual-network/a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:46,519 - DEBUG - Requesting: http://10.0.0.250:8082/routing-instance/9b286146-0f28-494d-9016-eb9441b630d6 2026-09-17 20:39:46,526 - DEBUG - Requesting: http://10.0.0.250:8082/routing-instance/9b286146-0f28-494d-9016-eb9441b630d6 2026-09-17 20:39:46,532 - DEBUG - Requesting: http://10.0.0.250:8082/route-target/8486f615-f99a-4bf1-8667-0ed80fc8ad56 2026-09-17 20:39:46,538 - DEBUG - Route Targets: ['target:64512:8000005'] 2026-09-17 20:39:46,538 - DEBUG - Requesting: http://10.0.0.250:8082/virtual-network/a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:46,547 - DEBUG - Requesting: http://10.0.0.250:8082/routing-instance/9b286146-0f28-494d-9016-eb9441b630d6 2026-09-17 20:39:46,562 - INFO - Verified VN network id 12 for VN a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:46,562 - INFO - Verifications in API Server for VN ctest-vn4-64763320 passed 2026-09-17 20:39:46,562 - DEBUG - Requesting: http://10.0.0.250:8082/virtual-network/a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:46,573 - DEBUG - Requesting: http://10.0.0.250:8082/routing-instance/9b286146-0f28-494d-9016-eb9441b630d6 2026-09-17 20:39:46,580 - DEBUG - Requesting: http://10.0.0.250:8082/routing-instance/9b286146-0f28-494d-9016-eb9441b630d6 2026-09-17 20:39:46,587 - DEBUG - Requesting: http://10.0.0.250:8082/route-target/8486f615-f99a-4bf1-8667-0ed80fc8ad56 2026-09-17 20:39:46,601 - DEBUG - Control-node 10.0.0.250 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-21473979:ctest-vn4-64763320', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-21473979', 'owner-access': '7', 'group': 'manager', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '11563832354063862967', 'uuid-lslong': '13479385823846181087'}, 'enable': 'true', 'created': '2026-09-17T20:39:45', 'last-modified': '2026-09-17T20:39:45', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.747194'} 2026-09-17 20:39:46,608 - DEBUG - Route Targets: ['target:64512:8000005'] 2026-09-17 20:39:46,608 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-64763320 passed 2026-09-17 20:39:46,608 - DEBUG - ====Verifying policy data for ctest-vn4-64763320 in API_Server ====== 2026-09-17 20:39:46,608 - DEBUG - Requesting: http://10.0.0.250:8082/domains 2026-09-17 20:39:46,614 - DEBUG - Requesting: http://10.0.0.250:8082/domain/a2e54ebb-b2d3-4607-b2a9-b4dd4b8880ff 2026-09-17 20:39:46,626 - DEBUG - Requesting: http://10.0.0.250:8082/project/b7189ee0-7dc0-4054-ae5c-24943e835c20 2026-09-17 20:39:46,704 - DEBUG - Requesting: http://10.0.0.250:8082/virtual-network/a07afc42-1a25-4cb7-bb10-65fd6cc9a8df 2026-09-17 20:39:46,715 - DEBUG - ==>Verifying data for policy with id: 312f400e-5ad9-45e5-9297-3091df7b864e, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-21473979', 'ctest-policy1-65550771'] 2026-09-17 20:39:46,715 - INFO - VN ctest-vn4-64763320 Policy verification: verify_vn_policy_in_api_server, status: True 2026-09-17 20:39:46,716 - DEBUG - Verifying the vn in opserver 2026-09-17 20:39:46,716 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-21473979:ctest-vn4-64763320 virtual network link through opserver 10.0.0.250 2026-09-17 20:39:46,716 - DEBUG - Requesting: http://10.0.0.250:8081/analytics/uves/virtual-networks 2026-09-17 20:39:47,044 - DEBUG - Requesting: http://10.0.0.250:8081/analytics/uves/virtual-networks 2026-09-17 20:39:47,097 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-21473979:ctest-vn4-64763320', 'href': 'http://10.0.0.250:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-21473979:ctest-vn4-64763320?flat'} 2026-09-17 20:39:47,097 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-21473979:ctest-vn4-64763320 is found in opserver 2026-09-17 20:39:47,109 - DEBUG - Do not have enough data to verify VN in agent 2026-09-17 20:39:47,113 - DEBUG - VRF ids for VN ctest-vn4-64763320: {} 2026-09-17 20:39:47,114 - DEBUG - ====Verifying data for ctest-policy1-65550771 in API_Server ====== 2026-09-17 20:39:47,114 - DEBUG - Requesting: http://10.0.0.250:8082/domains 2026-09-17 20:39:47,120 - DEBUG - Requesting: http://10.0.0.250:8082/domain/a2e54ebb-b2d3-4607-b2a9-b4dd4b8880ff 2026-09-17 20:39:47,132 - DEBUG - Requesting: http://10.0.0.250:8082/project/b7189ee0-7dc0-4054-ae5c-24943e835c20 2026-09-17 20:39:47,207 - DEBUG - Requesting: http://10.0.0.250:8082/network-policy/312f400e-5ad9-45e5-9297-3091df7b864e 2026-09-17 20:39:47,218 - INFO - Verified policy ctest-policy1-65550771 in API Server, Result: True 2026-09-17 20:39:47,218 - INFO - Done with setup and verification, moving onto test .. 2026-09-17 20:39:47,228 - INFO - Deleting VN ctest-vn4-64763320 2026-09-17 20:39:47,361 - DEBUG - Response for deleting network () 2026-09-17 20:39:47,361 - DEBUG - Requesting: http://10.0.0.250:8082/routing-instance/9b286146-0f28-494d-9016-eb9441b630d6 2026-09-17 20:39:47,367 - DEBUG - Response Code: 404 2026-09-17 20:39:47,367 - DEBUG - Requesting: http://10.0.0.250:8082/domains 2026-09-17 20:39:47,372 - DEBUG - Requesting: http://10.0.0.250:8082/domain/a2e54ebb-b2d3-4607-b2a9-b4dd4b8880ff 2026-09-17 20:39:47,427 - DEBUG - Requesting: http://10.0.0.250:8082/project/b7189ee0-7dc0-4054-ae5c-24943e835c20 2026-09-17 20:39:47,503 - INFO - Validated that VN ctest-vn4-64763320 is not found in API Server 2026-09-17 20:39:47,514 - DEBUG - VN ctest-vn4-64763320 is not present in Agent 10.0.0.250 2026-09-17 20:39:47,514 - INFO - Validated that VN ctest-vn4-64763320 is not in any agent 2026-09-17 20:39:47,531 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-64763320 info 2026-09-17 20:39:47,556 - INFO - Deleted policy ctest-policy1-65550771 2026-09-17 20:39:47,730 - DEBUG - policy ctest-policy1-65550771 is not found in API Server 2026-09-17 20:39:47,988 - DEBUG - No XMPP flaps were noticed during the test
2026-09-17 20:39:47,988 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:03]
2026-09-17 20:39:47,988 - INFO - -------------------------------------------------------------------------------- 2026-09-17 20:39:48,281 - DEBUG - No XMPP flaps were noticed during the test
2026-09-17 20:39:48,281 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:05]
2026-09-17 20:39:48,282 - INFO - -------------------------------------------------------------------------------- 2026-09-17 20:39:49,155 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-21473979, ID : b7189ee0-7dc0-4054-ae5c-24943e835c20