<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openstack/python-openstackclient.git/openstackclient/tests/functional, branch 5.2.0</title>
<subtitle>opendev.org: openstack/python-openstackclient
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/'/>
<entry>
<title>Merge "Fix faulthy state argument choice"</title>
<updated>2020-03-24T21:34:44+00:00</updated>
<author>
<name>Zuul</name>
<email>zuul@review.opendev.org</email>
</author>
<published>2020-03-24T21:34:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=81dcc91214c7b449e74ed5d0fe6854590431e6ef'/>
<id>81dcc91214c7b449e74ed5d0fe6854590431e6ef</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge "Now we can add description for role creation in OSC"</title>
<updated>2020-03-20T18:59:44+00:00</updated>
<author>
<name>Zuul</name>
<email>zuul@review.opendev.org</email>
</author>
<published>2020-03-20T18:59:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=fc12033f1da53fe11f930dd405eae5e2bf814621'/>
<id>fc12033f1da53fe11f930dd405eae5e2bf814621</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge "Create Volume v3 functional tests"</title>
<updated>2020-01-13T22:31:19+00:00</updated>
<author>
<name>Zuul</name>
<email>zuul@review.opendev.org</email>
</author>
<published>2020-01-13T22:31:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=4d9f0f384b910038240cf209dd9628eb6c2c41b9'/>
<id>4d9f0f384b910038240cf209dd9628eb6c2c41b9</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix openstack server list --deleted --marker option</title>
<updated>2020-01-02T20:05:56+00:00</updated>
<author>
<name>KeithMnemonic</name>
<email>keith.berger@suse.com</email>
</author>
<published>2019-10-24T18:39:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=f5384ae16a24cdd54149fa21827d14b8b8983d4f'/>
<id>f5384ae16a24cdd54149fa21827d14b8b8983d4f</id>
<content type='text'>
This patch removes using the "name" option for a marker when
--deleted is also used. The find_resource() function
that is being called does not correctly handle using the marker
as the "name" in the search when also using deleted=True.
One simple way to fix this is force the marker to only be an ID
when --deleted is used. This is how the nova client works.

Using the --deleted option is available to users with the admin
role by default. If you're an admin listing --deleted servers
with a marker by name, find_resource() is going to fail to find
it since it doesn't apply the --deleted filter to find_resource().

The find_resource() function is trying to find the marker server
by name if it's not found by id, and to find it by name it's
listing servers with the given marker as the name, but not
applying the --deleted filter so it doesn't get back any results.

In the story it was suggested modifying find_resource to include
the deleted query param when it's specified on the command line but
that didn't work because it still results in something like this:

http://192.168.1.123/compute/v2.1/servers?deleted=True&amp;name=4cecd49f-bc25-4a7e-826e-4aea6f9267d9

It seems like there are bugs in find_resource().

Restricting the marker to be the server ID when listing deleted servers
is probably OK since if you're using --deleted you're an admin and you could
be listing across all projects and if you're filtering by a server across all
projects anyway (not that you have to, I'm just saying if you are), or even
showing a server in another project, you have to do it by id rather than name
because find_resource() won't find the server in another project by name, only ID.

story: 2006761
Task: 37258

Change-Id: Ib878982b1d469212ca3483dcfaf407a8e1d2b417
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch removes using the "name" option for a marker when
--deleted is also used. The find_resource() function
that is being called does not correctly handle using the marker
as the "name" in the search when also using deleted=True.
One simple way to fix this is force the marker to only be an ID
when --deleted is used. This is how the nova client works.

Using the --deleted option is available to users with the admin
role by default. If you're an admin listing --deleted servers
with a marker by name, find_resource() is going to fail to find
it since it doesn't apply the --deleted filter to find_resource().

The find_resource() function is trying to find the marker server
by name if it's not found by id, and to find it by name it's
listing servers with the given marker as the name, but not
applying the --deleted filter so it doesn't get back any results.

In the story it was suggested modifying find_resource to include
the deleted query param when it's specified on the command line but
that didn't work because it still results in something like this:

http://192.168.1.123/compute/v2.1/servers?deleted=True&amp;name=4cecd49f-bc25-4a7e-826e-4aea6f9267d9

It seems like there are bugs in find_resource().

Restricting the marker to be the server ID when listing deleted servers
is probably OK since if you're using --deleted you're an admin and you could
be listing across all projects and if you're filtering by a server across all
projects anyway (not that you have to, I'm just saying if you are), or even
showing a server in another project, you have to do it by id rather than name
because find_resource() won't find the server in another project by name, only ID.

story: 2006761
Task: 37258

Change-Id: Ib878982b1d469212ca3483dcfaf407a8e1d2b417
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix faulthy state argument choice</title>
<updated>2019-12-19T08:48:17+00:00</updated>
<author>
<name>Bram Verschueren</name>
<email>verschueren.bram@gmail.com</email>
</author>
<published>2019-12-13T10:13:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=69870ae439f18863979949f5728543a0fb1cbe83'/>
<id>69870ae439f18863979949f5728543a0fb1cbe83</id>
<content type='text'>
The correct state name for a failing volume snapshot deletion is
'error_deleting' instead of 'error-deleting'. [1]

[1] https://opendev.org/openstack/cinder/src/commit/89d6a5042fcb2ede5a0b1112d72fae805ea52fcd/cinder/objects/fields.py#L126

Task: #37844
Story: #2007037

Change-Id: Ia99900ece4f1cd29769b22ddaa3965789d719556
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The correct state name for a failing volume snapshot deletion is
'error_deleting' instead of 'error-deleting'. [1]

[1] https://opendev.org/openstack/cinder/src/commit/89d6a5042fcb2ede5a0b1112d72fae805ea52fcd/cinder/objects/fields.py#L126

Task: #37844
Story: #2007037

Change-Id: Ia99900ece4f1cd29769b22ddaa3965789d719556
</pre>
</div>
</content>
</entry>
<entry>
<title>Create Volume v3 functional tests</title>
<updated>2019-11-18T20:47:56+00:00</updated>
<author>
<name>Dean Troyer</name>
<email>dtroyer@gmail.com</email>
</author>
<published>2019-11-18T20:44:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=1c0160c8aa8482958df54e0814023c5eeed0611e'/>
<id>1c0160c8aa8482958df54e0814023c5eeed0611e</id>
<content type='text'>
Until now-ish Volume v3 has been a pass-through to v2.  In order
to prepare to make the Volume v3 commands stand-alone copy the
v2 functional tests to v3.

This is the first of a series of reviews to completely separate
Volume v2 and v3 commands.  Once these are split we can begin to
implement v3 microversion support and/or start using the
OpenStack SDK as the REST library.

Change-Id: Iefd78d8ef6bb851d7360596337a88ee8f8476767
Signed-off-by: Dean Troyer &lt;dtroyer@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Until now-ish Volume v3 has been a pass-through to v2.  In order
to prepare to make the Volume v3 commands stand-alone copy the
v2 functional tests to v3.

This is the first of a series of reviews to completely separate
Volume v2 and v3 commands.  Once these are split we can begin to
implement v3 microversion support and/or start using the
OpenStack SDK as the REST library.

Change-Id: Iefd78d8ef6bb851d7360596337a88ee8f8476767
Signed-off-by: Dean Troyer &lt;dtroyer@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Refactor AggregateTests</title>
<updated>2019-11-05T21:32:15+00:00</updated>
<author>
<name>Eric Fried</name>
<email>openstack@fried.cc</email>
</author>
<published>2019-11-05T19:26:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=3b409e4d0e136380042a59a421ec4c4dc5b95c18'/>
<id>3b409e4d0e136380042a59a421ec4c4dc5b95c18</id>
<content type='text'>
While investigating the referenced story/bug I noticed that
wait_for_status in
openstackclient.tests.functional.compute.v2.test_aggregate.AggregateTests
was doing a lot more than it should ever need to (it probably got copied
in from somewhere). The two places calling it only need to a) check the
output of `openstack aggregate show`, and b) try once -- since they just
got done creating the aggregate synchronously, there should never be a
need to delay/retry. So this commit removes the helper method and just
inlines the check.

At the same time, the addCleanup(aggregate delete) directives are moved
above their respective creates. This is a defensive best practice which
makes sure cleanup happens even if something fails very soon after the
actual back-end create (as was in fact the case with the referenced
bug/story).

It is unknown whether this will impact the referenced bug.

Change-Id: I0d7432f13642fbccd5ca79da9c76adfcbabb5fa9
Story: 2006811
Related-Bug: #1851391
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
While investigating the referenced story/bug I noticed that
wait_for_status in
openstackclient.tests.functional.compute.v2.test_aggregate.AggregateTests
was doing a lot more than it should ever need to (it probably got copied
in from somewhere). The two places calling it only need to a) check the
output of `openstack aggregate show`, and b) try once -- since they just
got done creating the aggregate synchronously, there should never be a
need to delay/retry. So this commit removes the helper method and just
inlines the check.

At the same time, the addCleanup(aggregate delete) directives are moved
above their respective creates. This is a defensive best practice which
makes sure cleanup happens even if something fails very soon after the
actual back-end create (as was in fact the case with the referenced
bug/story).

It is unknown whether this will impact the referenced bug.

Change-Id: I0d7432f13642fbccd5ca79da9c76adfcbabb5fa9
Story: 2006811
Related-Bug: #1851391
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix functional tests for py3</title>
<updated>2019-10-31T00:17:35+00:00</updated>
<author>
<name>Eric Fried</name>
<email>openstack@fried.cc</email>
</author>
<published>2019-10-29T20:55:11+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=f1d742f32adeb662a3fdf8fa3ef3bc391e71ed81'/>
<id>f1d742f32adeb662a3fdf8fa3ef3bc391e71ed81</id>
<content type='text'>
Fix various things so the functional tests will work under python3:

- A hashlib.md5() can only be update()d with an encoded string in py3.
- There's no dict.iteritems(), change to dict.items() (which is already
  an iterator).
- Open temp files with 'w+' mode rather than the default 'w+b' (as an
  alternative to encoding all the write and expected-read payloads as
  bytes).
- (This is a weird one) Explicitly raise SkipTest from unittest (rather
  than unittest2, which is where cls.skipException landed). Not sure why
  this is busted, but this moves the ball.

Change-Id: Ic9b2b47848a600e87a3674289ae7ae8c3e091fee
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix various things so the functional tests will work under python3:

- A hashlib.md5() can only be update()d with an encoded string in py3.
- There's no dict.iteritems(), change to dict.items() (which is already
  an iterator).
- Open temp files with 'w+' mode rather than the default 'w+b' (as an
  alternative to encoding all the write and expected-read payloads as
  bytes).
- (This is a weird one) Explicitly raise SkipTest from unittest (rather
  than unittest2, which is where cls.skipException landed). Not sure why
  this is busted, but this moves the ball.

Change-Id: Ic9b2b47848a600e87a3674289ae7ae8c3e091fee
</pre>
</div>
</content>
</entry>
<entry>
<title>More aggregate functional race chasing</title>
<updated>2019-09-10T19:09:29+00:00</updated>
<author>
<name>Dean Troyer</name>
<email>dtroyer@gmail.com</email>
</author>
<published>2019-09-09T15:54:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=de8ab5e8fd05c3942a8ec332c01f4c92213f52d4'/>
<id>de8ab5e8fd05c3942a8ec332c01f4c92213f52d4</id>
<content type='text'>
AggregateTests.wait_for_status() was a classmethod, those often
are sources of conflict in parallel testing...

Change-Id: I6211fd9c36926ca97de51a11923933d4d9d2dfda
Signed-off-by: Dean Troyer &lt;dtroyer@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
AggregateTests.wait_for_status() was a classmethod, those often
are sources of conflict in parallel testing...

Change-Id: I6211fd9c36926ca97de51a11923933d4d9d2dfda
Signed-off-by: Dean Troyer &lt;dtroyer@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove races in floating ip functional tests</title>
<updated>2019-08-31T14:03:46+00:00</updated>
<author>
<name>Dean Troyer</name>
<email>dtroyer@gmail.com</email>
</author>
<published>2019-08-31T14:03:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/openstack/python-openstackclient.git/commit/?id=31c47adebb68b7ef508310bc9651fec0a26cd818'/>
<id>31c47adebb68b7ef508310bc9651fec0a26cd818</id>
<content type='text'>
Multiple subnets with the same name are occasionally created when
running tests in parallel.

Change-Id: Ifb85e39ee53b529e2b97abf782c7fba93d48e9e2
Signed-off-by: Dean Troyer &lt;dtroyer@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Multiple subnets with the same name are occasionally created when
running tests in parallel.

Change-Id: Ifb85e39ee53b529e2b97abf782c7fba93d48e9e2
Signed-off-by: Dean Troyer &lt;dtroyer@gmail.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
