7 Commits

Author SHA1 Message Date
Tang Chen
e69b88ef52 Fix DisplayCommandBase comments for cliff Lister subclass tests
As bug #1477199 describes, the wrong comment below is all over the
unit test code of OSC.

    # DisplayCommandBase.take_action() returns two tuples

There is no such class named DisplayCommandBase in OSC. It is in cliff.

All OSC command classes inherit from the base classes in cliff,
class Command, class Lister and class ShowOne. It is like this:

Object
|--> Command
     |--> DisplayCommandBase
          |--> Lister
          |--> ShowOne

take_action() is an abstract method of class Command, and generally is
overwritten by subclasses.
* Command.take_action() returns nothing.
* Lister.take_action() returns a tuple which contains a tuple of columns
  and a generator used to generate the data.
* ShowOne.take_action() returns an iterator which contains a tuple of
  columns and a tuple of data.

So, this problem should be fixed in 3 steps:
1. Remove all DisplayCommandBase comments for tests of classes inheriting
   from class Command in cliff as it returns nothing.
2. Fix all DisplayCommandBase comments for tests of classes inheriting
   from class Lister in cliff. Lister.take_action() returns a tuple and
   a generator.
3. Fix all DisplayCommandBase comments for tests of classes inheriting
   from class ShowOne in cliff. ShowOne.take_action() returns two tuples.

This patch finishes step 2 in all but identity tests. There are too many
such comments in identity tests. So fix them all in another patch.

Change-Id: I00f38d12f55abe20fa708f6349073da658622f8d
Partial-bug: #1477199
2016-02-09 20:28:18 +08:00
SaiKiran
030aee6fbc Changed the abstract columns and datalists from test cases of common and Identity
columns and datalist has been set in each test case in compute,
which is not necessary. This patch abstract it out and remove
all redundant code.

Change-Id: I45a3582088161f12e60e7c933da8e7dcc0ae8e7b
Closes-Bug: #1532384
2016-01-12 17:25:33 +05:30
Terry Howe
7aa6e5e36c SDK integration extensions and server create networks
Finish up the SDK integration with server create network and port
find and extension list.

Change-Id: I18dbada784d8aa92a45a937f251023ddf899c53e
2015-12-09 11:39:20 -07:00
TerryHowe
e7e8760fa6 Remove unnecessary test extension mock
The network extension test does not need this.

Change-Id: I8dd2cad759a813d7df0476afa6c56f455ddff616
2015-07-17 19:30:46 +00:00
wanghong
127af151ff fix the wrong order of assertEqual args
Let's fix them thoroughly.

Change-Id: I8a1f042fb614b05c9836a49041f3883638b870b0
2015-01-27 17:02:41 +08:00
Terry Howe
25e0d2ab27 Add network extension list
Network extension list support

Change-Id: I013f68ef2c3329c8db59e2441dd8d4ffafd4470e
Closes-Bug: #1337685
2014-07-26 15:57:48 -06:00
Matt Fischer
4ae4dc35bd Add support for extension list
- Add support in the common section for extension list. This only
   supports Identity for now. Once the APIs for volume and compute
   are supported in the respective APIs, they will be added. Once
   network is added to this client, it will be added (the API already
   supports it).
 - Include extension fakes for volume and compute for pre-enablement.

Change-Id: Iebb0156a779887d2ab06488a2a27b70b56369376
Closes-Bug: #1319115
2014-06-11 13:40:30 -06:00