[openstack-dev] [qa] API schema location

Christopher Yeoh cbkyeoh at gmail.com
Thu Mar 20 08:34:38 UTC 2014


On Tue, 18 Mar 2014 19:52:27 +0100
"Koderer, Marc" <m.koderer at telekom.de> wrote:

> > Am I missing something or are these schemas being added now just a
> > subset of what is being used for negative testing? Why can't we
> > either add the extra negative test info around the new test
> > validation patches and get the double benefit. Or have the negative
> > test schemas just extend these new schemas being added?
> 
> Yes, the api_schema files should theoretically be a
> subsets of the negative test schemas.
> But I don't think that extending them will be possible:
> 
> if you have a property definition like this:
> 
>         "properties": {
>             "minRam": {  "type": "integer",}
> 
> how can you extend it to:
> 
>         "properties": {
>             "minRam": {
>                 "type": "integer",
>                 "results": {
>                     "gen_none": 400,
>                     "gen_string": 400
>                 }
> 
> This is the reason why I am unsure how inheritance can solve
> something here.

I think this is an example of how we can do some sharing of schema
definitions when there is sufficient commonality to justify it.

Chris



More information about the OpenStack-dev mailing list