There is a bug in nova where the libvirt driver incorrectly removes
the local guest files for the hypervisor from shared storage because
it does not realize the instance is volume-backed. Nova runs an NFS
CI job in the experimental queue but it's not failing on resize
tests because they aren't volume-backed, so to recreate the failure
and make sure we don't regress the fix, this test is added. Nova
also runs a Ceph job which applies here too.
This moves the existing scenario test to be a compute API test. The
test ID is maintained in case people are blacklisting it, but the
slow tag is dropped because it's not a particularly slow test and
if the slow tag is applied, it won't actually be run in the jobs
that we care about testing this, e.g. NFS and Ceph jobs.
The additional wrinkle of getting the console log after the resize
is what shows the failure when the bug is not fixed, so that's added
here.
Depends-On: I29fac80d08baf64bf69e54cf673e55123174de2a
Change-Id: Id7de5186b2ea0ff7af86d9950c69203914498d88
Related-Bug: #1728603
services and extension decorators are based on CONF and needed by
Tempest only, so moving them to tempest.common.
Since a few plugnis use them today, use debtcollector to avoid
breaking all dependencies.
Change-Id: Ibd52153d00b8e60fb8c89e38d94e358ddc787251
I think it's a good idea to move all utility decorators into
tempest/lib/decorators.py. This patch does that for the `attr`
decorator.
Change-Id: Iaafbb112b6eee458089cc49918359a8a8d0485e2
This commit removes the skip condition with flavor_ref and
flavor_ref_alt when the resize feature is enable. Because when
resize feature is enable, the flavor_ref and flavor_ref_alt should be
set properly, otherwise, it is a misconfiguration. So we should fail
but not skip at the situation.
And This commit also add a help message for the resize config to avoid
users confusing.
Change-Id: I8eab2e57eb77e7a1a8dae7ffd63ec95ae6a026c3
The scenario tests end up generating a large load on target
environments. In most cases this means the whole system is running at
an extremely unrealisticly high load, and many of our scenario
failures are probably traceable back to this.
This classifies many more scenario tests as slow so that during normal
full runs they are not run, they are still accessible for running with
the tox -e all flag.
Selection based on https://ethercalc.openstack.org/nu56u2wrfb2b
Depends-on: Ia303773cabffc25d910cd1c0950d6739592bade6
Change-Id: I35cf4a77ff61d04ed8be58acff3edf47b1ae36f7
if CONF.compute.flavor_ref_alt == CONF.compute.flavor_ref,
test_server_sequence_suspend_resume will be skipped unexpectedly,
so the skip judgement shouldn't be put in skip_checks.
Besides, if flavor_ref_alt is not set, the resize testcase should
also be skipped.
Change-Id: I6bc3680ffa8c440590e234ce17bb57f06b361d02
In test_server_sequence_suspend_resume, show_server follows
wait_for_server_status which is meaningless, because in
wait_for_server_status if server didn't reach the expected
state, an exception will be raised.
This is to remove the unnecessary show_server and rearrange
the code so it can look clearer.
Change-Id: Ifbb3403cc68cf0ea4bd1f84e5972c74598c8d329
All callings to manager.create_server pass wait_until='ACTIVE',
so this is to make wail_until default as 'ACTIVE', not None.
Change-Id: I630cf047ed419fbf0cc073b5984fa29b456da451
So many modules are using test.idempotent_id and this is for
switching to decorators.idempotent_id on scenario.
Change-Id: Ieae5a2ee6937ad4339aff531eadc5e4986d7ec42
Related-Bug: #1616913
This test is basically new as of the last 24 hours and
breaks the ceph job which is gating on nova/cinder/glance/
os-brick/glance_store/gnocchi, so skip it based on the bug
for now.
Change-Id: I1f334f43175fe56bdbe6bd35655ce671df7600a7
Related-Bug: #1580625
test_server_advanced_ops.test_resize_server_confirm is a duplicate
of test_server_actions.test_resize_server_confirm, so rather than
delete it for being redundant, let's enhance it to be different.
There are currently no resize/migrate tests in Tempest which
resize a volume-backed instance, so this changes the scenario
test to use a volume-backed instance for the resize.
This change is pretty simple, but anyone that was blacklisting
the test based on the name would be broken. However, they should
be blacklisting on the test uuid anyway, so meh.
Related to nova blueprint libvirt-instance-storage
Change-Id: Ie91b2881cb59638ac6e533ab93024dbc42111772
Migrate the scenario tests to the new ssh-auth-strategy.
Partially implements: blueprint ssh-auth-strategy
Change-Id: I50759d32e47d975ec64ca129a13b2ae4459917e4
There is a lot of H404/405 violations in Tempest now, and that leads
difficult to migrate the code to tempest-lib or the other projects'
repos. This patch fixes these violations for scenario tests.
Change-Id: Ia2b3cdbd0da49eeb16742c1eed05ea56ca41a8f7
Currently compute servers_client returns Response by
removing top key from Response.
For example-
return service_client.ResponseBody(resp, body['server'])
As service clients are in direction to move to Tempest-lib, all
service clients should return Response without any truncation.
One good example is Resource pagination links which are lost with current
way of return value. Resource pagination links are present in parallel
(not inside) to top key of Response.
This patch makes compute servers_client to return
complete Response body.
Change-Id: I6a7b5c6144cafcb8f0780db01bf67999a4229389
Implements: blueprint method-return-value-and-move-service-clients-to-lib
As the qa-spec of consistent-service-method-names, basically all
methods’ names should be "<verb>_<resource/object name>".
Ib91dc75055b9e2331d243cac686fe19c7516f6ba added the word "server"
to compute action methods, but it didn't cover some action methods.
So this patch tries it again for covering all action methods.
Partially implements blueprint consistent-service-method-names
Change-Id: I5ba600d33c600b515a49bd36fbb111502f6849c1
As the qa-spec of consistent-service-method-names, basically all
methods’ names should be "<verb>_<resource/object name>".
So this patch adds the word "server" to compute action methods.
Partially implements blueprint consistent-service-method-names
Change-Id: Ib91dc75055b9e2331d243cac686fe19c7516f6ba
wait_for_server_status of compute client just calls the one of waiters
module and the method is a wrapper.
So the method seems redundant and it doesn't fit as service clients.
This patch removes wait_for_server_status from compute client and
replaces it with waiters' one.
Partially implements blueprint consistent-service-method-names
Change-Id: Ie821ea4ba0924b71caba80132e1c383fb5bb125d
[GET /resources] methods should be "list_<resource name>s"
or "show_<resource name>", so this patch applies the rule
to show_server method of compute clients.
Partially implements blueprint consistent-service-method-names
Change-Id: I92addd2ad6502fe00395e2b9455de25c2f53d115
Use graduated libraries where available and update the incubated modules
that remain.
Update imports for libraries that were being used already to avoid the
'oslo' namespace package.
Update config file for creating example configuration files and provide
a new sample file based on the options defined in the libraries.
Note: because of the number of libraries involved there is no real way
to break this change up into smaller pieces. Fortunately, most of the
changes are just to import statements.
Change-Id: Ia0de957b681cb924a57af98d99a9389ee234ed5b
Split up the resource_setup method for all the scenario tests.
Partially-implements bp:resource-cleanup
Change-Id: Ic26799f5669b9eae23c462eb9f36637dbd11d574
Adds uuid4 as a decorator of the form:
@test.idempotent_id('12345678-1234-1234-1234-123456789abc')
to every test in the Tempest tree. Includes a gate check to
ensure the existence and uniqueness of the ids.
Modify check tool to ignore Tempest unit tests.
Change-Id: I19e3c7dd555a3ea09d585fb9091c357a300e6559
Co-Authored-By: Sergey Slipushenko <sslypushenko@mirantis.com>
Implements: bp test-uuid
This includes create_server, update_server, get_server, delete_server and
also some helper methods such as create_test_server
Partially implements: blueprint clients-return-one-value
Change-Id: I8e1fba7a31a0ed27e683dacd9a8e763759552c11
As resource_setup() document says, we should check skip condition before
resource_setup. However some functions in scenarios setup resources
before skip checks. We should avoid to setup unnecessary resources as
possible. This commit fixes the order.
Change-Id: Id0529fc80f2b80f028fd078140fe5fd7459e9309
This patch migrate the server advanced ops scenario tests
from official client to tempest clients.
This patch also correct some logging
For example -
During Suspending and Resuming the instance current state of instance
was wrong in log meggase.
Partially-implements: bp:tempest-client-scenarios
Change-Id: I5bad550e64d8226e479c28b74378d812a629e2d0
Some tests missed checking for compute features as
set in compute-feature-enabled section in tempest.conf.
Reduce double-coverage of pause/suspend tests between
basic and advanced server tests by removing pause and
suspend actions in basic ops test.
Closes-bug: 1296858
Change-Id: I80d785bb5b325ccfac3c5cfd9d076718cf587e80
We can use H302 rule but ignore it now. This commit prepares for
enabling H302 rule. But this commit modifies tempest/scenario only
and excludes some violations[1] because if we fix all of them at one
time, it's hard to merge this commit.
[1]
tempest.test.attr
tempest.common.rest_client.RestClient
tempest.common.rest_client.RestClientXML
tempest.services.compute.xml.common.xml_to_json
tempest.services.compute.xml.common.Element
tempest.services.compute.xml.common.Document
tempest.services.compute.xml.common.Text
tempest.services.compute.xml.common.XMLNS_11
tempest.services.compute.xml.common.XMLNS_V3
tempest/clients.py
Change-Id: I57c26ef681120a9ee826b9cef26d1aaa734d69e5
This commit takes all the uses of config in the scenario tests and
converts them to use the global CONF object.
Partially implements bp config-cleanup
Change-Id: I1bac686587f1705901b653b07300077623ba9f21
We don't need to have the vim headers in each source files. We can set
it in our vimrc file instead. Also if set incorrectly, gate (pep8 check)
will catch the mistakes.
More discussions:
http://lists.openstack.org/pipermail/openstack-dev/2013-October/017353.html
Change-Id: I43703e2289212389c7841f44691ae7849ed1f505
Closes-Bug: #1229324
This patch leverages the set_network_resources method in
order to limit the network resources used.
Change-Id: Ia7defc783b5f55504e6c6923069f989a389a639f
This commit reorganizes the config options for each project into
separate groups. This makes it easier to identify where to set
which features are enabled.
Partially Implements: blueprint config-cleanup
Change-Id: Idf8c65ef9bbc11cadea236f0b1a491a0f82bb84b
this makes passing the client optional to create_server and
create_security_group as it happens with the other utility methods
Change-Id: I56f7a4078d1da0c7b5bd7c493eb480d640be2805
Some files still use trademark OpenStack LLC in header, which
should be changed to OpenStack Foundation.
NOTE: tools/install_venv.py is not synced from oslo-incubator, so
it is modified too.
Change-Id: I0084684ff5225076291fea857eb010d638291bd0
Fixes-Bug: #1214176
This patch changes "create server" implementation from each
implementation to the common method for code clean-up.
Change-Id: I04daf642ffdf5df6c7e5822f5f3c2281b0958a03
This commit add service tags to all the test methods in the scenario
tests.
Part of bp add-service-tags
Change-Id: I9f4e125d05eeffd2dc2cbdc2b6346897166afad8
This commit removes the tempest.common.log module and switches to
using the Oslo log module. The Oslo log module is required by
lockutils and it's dependent modules, so this patch migrates all of
Tempest to it so that there is only one logger in the project. This
also has the advantage of bringing Tempest's logging configuration
in line with other OpenStack projects.
Change-Id: I31b460e454123a4211c0a8a1dc91bbfd562ce81a
When added the testresources added as base class the resource variable usage
changed, and it renamed to os_resources in the other places.
TestServerAdvancedOps still want to use the old variable,
however the base class has proper tearDownClass method.
Let the TestServerAdvancedOps to use the base class's tearDownClass.
Fixes Bug 1157306
Change-Id: I9bc1c90d526865cafbc6fbf71172aae10e95cb7d
Test verify sequence instance suspend-resume
After second resume operation instace should be in Active state.
Change-Id: I94e74dad19cd932d45c3e201a454e7665a0b664d
Now we can get tempest log file with options in run_tests.sh.
This adds log.py and enables to configure log format more flexibly
using configuration file.
This adds a LoggerAdaptor and a Formatter to output each test name
to log lines.
Implements: blueprint add-logging-configuration
Change-Id: I88cf18bb8bbc152e62ac83a9c7dc26067b7a11bd
this adds the scenario directory as part of the tempest
restructure, and moves scenario tests over to the new directory.
To ensure we got everything that used the old DefaultClient and
DefaultManager classes these are refactored out into the scenario
directory as OfficialClient and OfficialClientManager.
The Nework Smoke test base class becomes NetworkScenarioTest, and
the two test files that used that come over to scenario directory
in the process.
These are all done with a single tempest/scenario/manager.py file
for now. As the scenario tests grow we'll figure out better
refactorings there.
This gives us 4 scenario test files as a starting point for future
scenario work.
Fixed remaining refactor issues with network tests
Clean up the documentation on the extracted classes
Part of bp:tempest-repo-restructure
Change-Id: I143b282c58cfac3bf979ba5ac68226155beff343