[openstack-dev] [qa] Use test scenarios for interface type and auth version
robertc at robertcollins.net
Sat Jan 4 01:29:59 UTC 2014
On 4 January 2014 04:14, Frittoli, Andrea (Cloud Services)
<frittoli at hp.com> wrote:
> I’m working on multi-keystone-api-version-tests which aims to provide the
> ability to run tests using a configurable list of keystone API versions for
> If two versions of the API are configured, each test would be run using the
> two versions.
> In the gate, where we’re short of time, we could test only the latest stable
> version, but in other tests will have the ability to use more than one
> The approach I’m considering is based on testscenarios.
> Thinking about how to implement this I recognized that a solution that works
> for auth version could be used also to run json / xml, removing the need to
> have two classes for API test.
> The idea I have is to change Base[Service]Test classes and move the client
> selection logic to BaseTestCase. Something like this:
> def __getattr__(self, attr):
> if attr in
> self.auth_version, self.interface)
> raise AttributeError
Ugh, don't override __getattr__ (or __getattribute__) for something
like this. ETOOMUCHMAGIC.
def self.get_client(self, attr):
Will be much more obvious.
Robert Collins <rbtcollins at hp.com>
HP Converged Cloud
More information about the OpenStack-dev