Reviewed: https://review.openstack.org/439428 Committed: https://git.openstack.org/cgit/openstack/tempest/commit/?id=7d8f7c5669f42178ae47aa1a6446eda42910a390 Submitter: Jenkins Branch: master
commit 7d8f7c5669f42178ae47aa1a6446eda42910a390 Author: zhufl <email address hidden> Date: Wed Mar 1 15:41:41 2017 +0800
Correct test_list_servers_filtered_by_ip for bug 1668828"
test_list_servers_filtered_by_ip will fail occasionally, because now on Nova side filter by ip is always "regexp match", https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/schemas/servers.py#L355 so if server1's ip is "10.1.1.1" and servers2's ip is "10.1.1.10", filter by server1's ip "10.1.1.1" will get both servers in the list.
This is to use the longest ip for the filter, i.e., if server1's ip is "10.1.1.1" and server2's ip is "10.1.1.10", then we should use "10.1.1.10" for the filter, so to ensure only one server is returned in the list.
Change-Id: I87c325cb80a95861287c54fbd1b5718cfb9ef310 Closes-Bug: #1668828
Reviewed: https:/ /review. openstack. org/439428 /git.openstack. org/cgit/ openstack/ tempest/ commit/ ?id=7d8f7c5669f 42178ae47aa1a64 46eda42910a390
Committed: https:/
Submitter: Jenkins
Branch: master
commit 7d8f7c5669f4217 8ae47aa1a6446ed a42910a390
Author: zhufl <email address hidden>
Date: Wed Mar 1 15:41:41 2017 +0800
Correct test_list_ servers_ filtered_ by_ip for bug 1668828"
test_ list_servers_ filtered_ by_ip will fail occasionally, because /github. com/openstack/ nova/blob/ master/ nova/api/ openstack/ compute/ schemas/ servers. py#L355
now on Nova side filter by ip is always "regexp match",
https:/
so if server1's ip is "10.1.1.1" and servers2's ip is "10.1.1.10",
filter by server1's ip "10.1.1.1" will get both servers in the list.
This is to use the longest ip for the filter, i.e., if server1's
ip is "10.1.1.1" and server2's ip is "10.1.1.10", then we should use
"10.1.1.10" for the filter, so to ensure only one server is returned
in the list.
Change-Id: I87c325cb80a958 61287c54fbd1b57 18cfb9ef310
Closes-Bug: #1668828