2026-02-03 18:43:18,121 - INFO - Domain Default found not creating 2026-02-03 18:43:18,302 - INFO - Project ctest-TestBasicPolicyNegativeIpv4v6-58947636 not found, creating it 2026-02-03 18:43:18,774 - INFO - Created Project:ctest-TestBasicPolicyNegativeIpv4v6-58947636, ID : 3c70b1d6-717a-4b48-bd78-58150fc5546b 2026-02-03 18:43:20,244 - INFO - ================================================================================ 2026-02-03 18:43:20,244 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-02-03 18:43:20,500 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2026-02-03 18:43:20,500 - INFO - Initial checks done. Running the testcase now 2026-02-03 18:43:20,500 - INFO - 2026-02-03 18:43:20,500 - INFO - ================================================================================ 2026-02-03 18:43:20,501 - INFO - STARTING TEST : test_remove_policy_with_ref 2026-02-03 18:43:20,501 - 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-02-03 18:43:20,789 - DEBUG - Nothing to compare xmpp stats {'10.0.0.50': {'10.20.0.17': '0'}} with 2026-02-03 18:43:20,789 - INFO - Initial checks done. Running the testcase now 2026-02-03 18:43:20,789 - INFO - 2026-02-03 18:43:21,151 - DEBUG - Policy np_rules : [rule_sequence = None, rule_uuid = None, direction = <>, protocol = icmp, src_addresses = [subnet = None, virtual_network = default-domain:ctest-TestBasicPolicyNegativeIpv4v6-58947636:ctest-vn4-28080544, 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-58947636:ctest-vn4-28080544, 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-58947636:ctest-vn4-28080544, 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-58947636:ctest-vn4-28080544, 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-02-03 18:43:21,659 - DEBUG - Response for create_network : {'network': {'id': '5d35340d-ccb7-4f75-aa20-174918e8eaf1', 'name': 'ctest-vn4-28080544', 'tenant_id': '3c70b1d6717a4b48bd7858150fc5546b', 'project_id': '3c70b1d6717a4b48bd7858150fc5546b', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': [], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-58947636', 'ctest-vn4-28080544'], 'port_security_enabled': True, 'description': ''}} 2026-02-03 18:43:21,847 - DEBUG - Response for create_subnet : {'subnet': {'id': 'eac121ef-047f-468f-a2e0-a99c535adcf3', 'name': '', 'tenant_id': '3c70b1d6717a4b48bd7858150fc5546b', 'network_id': '5d35340d-ccb7-4f75-aa20-174918e8eaf1', 'ip_version': 4, 'cidr': '206.159.126.64/26', 'allocation_pools': [{'start': '206.159.126.66', 'end': '206.159.126.126'}], 'gateway_ip': '206.159.126.65', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '206.159.126.66', 'tags': [], 'project_id': '3c70b1d6717a4b48bd7858150fc5546b'}} 2026-02-03 18:43:22,068 - DEBUG - Response for create_subnet : {'subnet': {'id': 'e1a9c639-f7b8-4995-925a-b85c26b27771', 'name': '', 'tenant_id': '3c70b1d6717a4b48bd7858150fc5546b', 'network_id': '5d35340d-ccb7-4f75-aa20-174918e8eaf1', 'ip_version': 6, 'cidr': '22e9:ddad:7f09:1899:ce8c:50a5::/96', 'allocation_pools': [{'start': '22e9:ddad:7f09:1899:ce8c:50a5:0:2', 'end': '22e9:ddad:7f09:1899:ce8c:50a5:ffff:fffe'}], 'gateway_ip': '22e9:ddad:7f09:1899:ce8c:50a5:0:1', 'enable_dhcp': True, 'ipv6_ra_mode': None, 'ipv6_address_mode': None, 'dns_nameservers': [], 'host_routes': [], 'dns_server_address': '22e9:ddad:7f09:1899:ce8c:50a5:0:2', 'tags': [], 'project_id': '3c70b1d6717a4b48bd7858150fc5546b'}} 2026-02-03 18:43:22,088 - INFO - Created VN ctest-vn4-28080544 2026-02-03 18:43:22,139 - DEBUG - VN ctest-vn4-28080544 UUID is 5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:22,343 - DEBUG - Response for mapping policy(s) with vn {'network': {'id': '5d35340d-ccb7-4f75-aa20-174918e8eaf1', 'name': 'ctest-vn4-28080544', 'tenant_id': '3c70b1d6717a4b48bd7858150fc5546b', 'project_id': '3c70b1d6717a4b48bd7858150fc5546b', 'admin_state_up': True, 'shared': False, 'status': 'ACTIVE', 'router:external': False, 'mtu': 0, 'subnets': ['eac121ef-047f-468f-a2e0-a99c535adcf3', 'e1a9c639-f7b8-4995-925a-b85c26b27771'], 'fq_name': ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-58947636', 'ctest-vn4-28080544'], 'policys': [['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-58947636', 'ctest-policy1-75117426']], 'subnet_ipam': [{'subnet_cidr': '206.159.126.64/26', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}, {'subnet_cidr': '22e9:ddad:7f09:1899:ce8c:50a5::/96', 'ipam_fq_name': ['default-domain', 'default-project', 'default-network-ipam']}], 'port_security_enabled': True, 'description': ''}} 2026-02-03 18:43:22,503 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-02-03 18:43:22,796 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-02-03 18:43:22,829 - DEBUG - Requesting: http://10.0.0.50:8082/domain/0b7ce9ba-4407-4921-ac3c-b6fa2ad0e050 2026-02-03 18:43:22,840 - DEBUG - Requesting: http://10.0.0.50:8082/project/3c70b1d6-717a-4b48-bd78-58150fc5546b 2026-02-03 18:43:22,916 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:22,927 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:22,937 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4bded9d9-d759-42bc-933a-eaa5024e7d50 2026-02-03 18:43:22,946 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4bded9d9-d759-42bc-933a-eaa5024e7d50 2026-02-03 18:43:22,954 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/59b5d1b3-9295-4f99-9d65-6f332306309f 2026-02-03 18:43:22,961 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-02-03 18:43:22,961 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:22,972 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4bded9d9-d759-42bc-933a-eaa5024e7d50 2026-02-03 18:43:22,989 - INFO - Verified VN network id 9 for VN 5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:22,990 - INFO - Verifications in API Server for VN ctest-vn4-28080544 passed 2026-02-03 18:43:22,990 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:23,001 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4bded9d9-d759-42bc-933a-eaa5024e7d50 2026-02-03 18:43:23,008 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4bded9d9-d759-42bc-933a-eaa5024e7d50 2026-02-03 18:43:23,014 - DEBUG - Requesting: http://10.0.0.50:8082/route-target/59b5d1b3-9295-4f99-9d65-6f332306309f 2026-02-03 18:43:23,025 - DEBUG - Control-node 10.0.0.50 : VN object is : {'node_name': 'virtual-network:default-domain:ctest-TestBasicPolicyNegativeIpv4v6-58947636:ctest-vn4-28080544', 'interests': '-', 'advertised': '-', 'dbentryflags': None, 'obj_info': {'sequence_number': '0', 'origin': 'Cassandra', 'data': {'id-perms': {'permissions': {'owner': 'ctest-TestBasicPolicyNegativeIpv4v6-58947636', 'owner-access': '7', 'group': 'admin', 'group-access': '7', 'other-access': '7'}, 'uuid': {'uuid-mslong': '6716331653166747509', 'uuid-lslong': '12258823788420459249'}, 'enable': 'true', 'created': '2026-02-03T18:43:21', 'last-modified': '2026-02-03T18:43:22', 'description': None, 'user-visible': 'true', 'creator': None}}}, 'neighbors': None, 'last_modified': '00:00:00.720346'} 2026-02-03 18:43:23,030 - DEBUG - Route Targets: ['target:64512:8000004'] 2026-02-03 18:43:23,031 - INFO - On all control nodes, Config, RI and RT verification for VN ctest-vn4-28080544 passed 2026-02-03 18:43:23,031 - DEBUG - ====Verifying policy data for ctest-vn4-28080544 in API_Server ====== 2026-02-03 18:43:23,031 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-02-03 18:43:23,036 - DEBUG - Requesting: http://10.0.0.50:8082/domain/0b7ce9ba-4407-4921-ac3c-b6fa2ad0e050 2026-02-03 18:43:23,046 - DEBUG - Requesting: http://10.0.0.50:8082/project/3c70b1d6-717a-4b48-bd78-58150fc5546b 2026-02-03 18:43:23,119 - DEBUG - Requesting: http://10.0.0.50:8082/virtual-network/5d35340d-ccb7-4f75-aa20-174918e8eaf1 2026-02-03 18:43:23,128 - DEBUG - ==>Verifying data for policy with id: 4aabd6ce-84bb-45bf-8202-cb05aae6ef53, fqn: ['default-domain', 'ctest-TestBasicPolicyNegativeIpv4v6-58947636', 'ctest-policy1-75117426'] 2026-02-03 18:43:23,128 - INFO - VN ctest-vn4-28080544 Policy verification: verify_vn_policy_in_api_server, status: True 2026-02-03 18:43:23,128 - DEBUG - Verifying the vn in opserver 2026-02-03 18:43:23,128 - DEBUG - Verifying the default-domain:ctest-TestBasicPolicyNegativeIpv4v6-58947636:ctest-vn4-28080544 virtual network link through opserver 10.0.0.50 2026-02-03 18:43:23,128 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-02-03 18:43:23,423 - DEBUG - Requesting: http://10.0.0.50:8081/analytics/uves/virtual-networks 2026-02-03 18:43:23,479 - DEBUG - vn link and name as {'name': 'default-domain:ctest-TestBasicPolicyNegativeIpv4v6-58947636:ctest-vn4-28080544', 'href': 'http://10.0.0.50:8081/analytics/uves/virtual-network/default-domain:ctest-TestBasicPolicyNegativeIpv4v6-58947636:ctest-vn4-28080544?flat'} 2026-02-03 18:43:23,479 - INFO - Validated that VN default-domain:ctest-TestBasicPolicyNegativeIpv4v6-58947636:ctest-vn4-28080544 is found in opserver 2026-02-03 18:43:23,488 - DEBUG - Do not have enough data to verify VN in agent 2026-02-03 18:43:23,492 - DEBUG - VRF ids for VN ctest-vn4-28080544: {} 2026-02-03 18:43:23,492 - DEBUG - ====Verifying data for ctest-policy1-75117426 in API_Server ====== 2026-02-03 18:43:23,492 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-02-03 18:43:23,497 - DEBUG - Requesting: http://10.0.0.50:8082/domain/0b7ce9ba-4407-4921-ac3c-b6fa2ad0e050 2026-02-03 18:43:23,507 - DEBUG - Requesting: http://10.0.0.50:8082/project/3c70b1d6-717a-4b48-bd78-58150fc5546b 2026-02-03 18:43:23,576 - DEBUG - Requesting: http://10.0.0.50:8082/network-policy/4aabd6ce-84bb-45bf-8202-cb05aae6ef53 2026-02-03 18:43:23,590 - INFO - Verified policy ctest-policy1-75117426 in API Server, Result: True 2026-02-03 18:43:23,590 - INFO - Done with setup and verification, moving onto test .. 2026-02-03 18:43:23,597 - INFO - Deleting VN ctest-vn4-28080544 2026-02-03 18:43:23,719 - DEBUG - Response for deleting network () 2026-02-03 18:43:23,719 - DEBUG - Requesting: http://10.0.0.50:8082/routing-instance/4bded9d9-d759-42bc-933a-eaa5024e7d50 2026-02-03 18:43:23,724 - DEBUG - Response Code: 404 2026-02-03 18:43:23,724 - DEBUG - Requesting: http://10.0.0.50:8082/domains 2026-02-03 18:43:23,729 - DEBUG - Requesting: http://10.0.0.50:8082/domain/0b7ce9ba-4407-4921-ac3c-b6fa2ad0e050 2026-02-03 18:43:23,784 - DEBUG - Requesting: http://10.0.0.50:8082/project/3c70b1d6-717a-4b48-bd78-58150fc5546b 2026-02-03 18:43:23,857 - INFO - Validated that VN ctest-vn4-28080544 is not found in API Server 2026-02-03 18:43:23,867 - DEBUG - VN ctest-vn4-28080544 is not present in Agent 10.0.0.50 2026-02-03 18:43:23,867 - INFO - Validated that VN ctest-vn4-28080544 is not in any agent 2026-02-03 18:43:23,879 - INFO - Validated that Routing instances and Config db in Control-nodes does not have VN ctest-vn4-28080544 info 2026-02-03 18:43:23,903 - INFO - Deleted policy ctest-policy1-75117426 2026-02-03 18:43:24,067 - DEBUG - policy ctest-policy1-75117426 is not found in API Server 2026-02-03 18:43:24,319 - DEBUG - No XMPP flaps were noticed during the test
2026-02-03 18:43:24,319 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2026-02-03 18:43:24,319 - INFO - -------------------------------------------------------------------------------- 2026-02-03 18:43:24,607 - DEBUG - No XMPP flaps were noticed during the test
2026-02-03 18:43:24,607 - INFO - END TEST : test_remove_policy_with_ref : PASSED[0:00:04]
2026-02-03 18:43:24,607 - INFO - -------------------------------------------------------------------------------- 2026-02-03 18:43:25,288 - INFO - Deleted project: ctest-TestBasicPolicyNegativeIpv4v6-58947636, ID : 3c70b1d6-717a-4b48-bd78-58150fc5546b