10 Commits

Author SHA1 Message Date
Sean Dague
d8673cb256 remove processing of blacklist/whitelist/corelist extensions
This removes the facility in the API router to have limited lists of
extensions. From this point forward, what is in Nova is loaded, no
exceptions.

A number of unit tests and fakes have to be updated to pass after
this, as many unit tests were sending small lists of extensions to the
API router to simplify the responses they were getting back. This also
required stubbing out the request db cache in some cases, because
extensions later get content from there to avoid additional db
hits. As well as adjusting a few samples tests which now return more
data because all the extensions are always loaded.

There is much cleanup to happen after this, but this is the smallest
unit to get us over this boundary which will start letting us to
refold extensions back into the base views (and massively simplify the
API code).

This does not yet remove the config options because there is another
place those get used in servers.py and the testing fallout of that is
much bigger.

The reno will come with that patch.

Change-Id: I3e72f5e23ce39148f31dfdb76d18f403c6d04842
2016-06-10 11:37:09 -04:00
Sean Dague
0c57f3c4e0 Drop the use of magic openstack project_id
When we put validation into the project_id in urls we had to expand
the default set of allowed values to include 'openstack' and
'fake'. This cleans up all the instances of 'openstack' in the
functional tests, and api samples, and instead uses a constant string
which looks like a real project_id.

We need a stable project_id and not a sentinel otherwise the samples
will be arbitrarily changes on every update.

Change-Id: I1099fd43d2374abd1658b0917765d5375c4b8d1d
2016-03-08 19:34:56 +00:00
Jenkins
c5c99fe968 Merge "remove nova-cert from most functional tests" 2015-12-21 09:05:10 +00:00
Sean Dague
f9f3946e0d Use just ids in all request templates for flavors/images
While the API allows for strings which happen to end in an ID for
flavorRef/imageRef, the common path is really just the ID itself, and
we should have the samples do this. The use of full urls in our
samples makes it seem like this is more meaningful than it really is,
and that you could pass a url to a remote system, for instance, which
won't work at all.

Change-Id: I669619b627f954232712d54498b3744353d25451
2015-12-17 13:01:28 -05:00
Sean Dague
af55385203 remove nova-cert from most functional tests
nova-cert is only needed for 1 API resource (os-certificates) and the
ec2 api. We don't need to run it on all the other functional
tests. Getting rid of a service start / stop on all of them shaves a
little time off each test, and means noise in logs.

Change-Id: I175b8913fe5d19c8b552c60c793565c042c6b874
2015-12-17 10:54:08 -05:00
Sean Dague
7974f83743 Remove cells service from api samples that don't test cells
Instead of having cells service started for every api samples test,
whether or not it is used, only start it on test_cells. This saves
some setup / teardown time, and makes things a bit more explicit.

It also removes the cells service from service listing for a couple of
api samples (az and hosts). That's more indicative of what people will
see in real systems as cells is still a minority and experimental
deploy option.

Change-Id: Ie6d7e8978fd2b3441a141c69d4191266d76e7327
2015-12-14 10:16:52 -05:00
He Jie Xu
9f9802eebd Move the v2 api_sample functional tests
This patch move the all v2.1 api sample tests under
'functional/api_sample_tests'. Also move sample files under
'doc/api-samples'.

Co-Authored-By: Ed Leafe <ed@leafe.com>
Co-Authored-By: Alex Xu <hejie.xu@intel.com>
Partial-Bug: #1462901
Change-Id: I2b924f2ad7687a23a018a9b658e8acd9e04d7963
2015-08-18 15:25:41 +08:00
ghanshyam
79c47a0919 Merge availability_zone tests between v2 and v2.1
Currently v2 and v2.1 have separate functional tests and their
corresponding sample files. As v2 and v2.1 are supposed to be identical,
there is overhead to maintain two set of functional tests and sample files.
We can have one set of tests which can run for both v2 and v2.1.

This commit merges availability_zone functional tests.

In V2.1 os-access-ip is separate plugin where in v2 it was mixed in server
plugin itself. So os-access-ip extension is enabled to run
merged functional tests for both v2 and v2.1.
Also enabling some required extension for v2 tests.

Change-Id: I82e7011da212cb4699c4c19b95523a54a6c2f259
2015-07-06 23:58:06 +00:00
Davanum Srinivas
417704816e Nuke XML support from Nova REST API - Phase 1
In I5a580fc323c3809790b4a68a9f8f8129ecdc2cf0 we switched off XML support. In
this review we entirely remove all the testcases and supporting files.

Change-Id: I83827d438753fd3899053dd6e09bc77c997c7406
2015-01-05 12:46:04 -05:00
Matthew Treinish
7fbe9ad597 Add availability zone extension to API samples test.
Change-Id: I43e64d6637ef850119475c5d470cc54e7168c388
Signed-off-by: Matthew Treinish <treinish@linux.vnet.ibm.com>
2012-10-24 17:10:04 -04:00