[openstack-dev] [openstack][tempest] keystoneclient API tests

Brant Knudson blk at acm.org
Fri Dec 6 01:26:47 UTC 2013

I thought I'd get started looking at how we could get some
python-keystoneclient testing into tempest. Unfortunately I missed the
summit meeting about this so maybe this was discussed, but I don't see any
details mentioned on the etherpad:

I can think of several ways to do this, from starting from scratch to
moving the tests wholesale from keystone to tempest.

The method I've been looking at today is making the existing identity REST
API tests use the python API. This seemed like a reasonable way to go,
since then rather than having a brand new set of tests we can re-use what's
already there, and if we develop new tests to cover the REST API we get
coverage of the python API and new tests for the python API will also
exercise the REST API.

So what this entails is providing a new "api" client. There are "json" and
"xml" clients already. The "api" client would use the python API rather
than the REST API that json and xml use. Note that this is already kind of
weird because there are "json" and "xml" clients for compute, image, etc,
that are all used together, whereas I'd only be implementing an "api"
client for identity.

A stumbling block here is that the tempest tests make assumptions about the
results of the identity functions being called... the REST APIs are
returning dicts while the python API returns python objects. There's a
couple of ways to go here, try to change the test harness so that it's not
making assumptions, have the "api" client translate responses so their like
the REST responses, or have the "json" and "xml" clients translate to be
like "api" responses.

So I'm just looking for feedback from "someone" more familiar with tempest
as to whether one method (copy from keystone, implement an "api" client,
etc.) seems more reasonable, or if there's other ideas for how to get the
keystoneclient API tests into tempest.

- Brant
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20131205/d33a3d66/attachment.html>

More information about the OpenStack-dev mailing list