158 Commits

Author SHA1 Message Date
Manjeet Singh Bhatia
5d404ecd05 Add functional tests for IP availability
This patch adds functional tests for IP availability

Partially-Implements: blueprint neutron-ip-capacity
Change-Id: I1c1dc01801707fe8f0dc3c976e5d345d2b0db0ec
2016-06-06 17:43:57 +00:00
Richard Theis
6f2c1734e3 Fix --enable options on commands
The --enable option on commands is ignored when the arguments are parsed.
This is related to the --enable-beta-commands option. Renaming the option
to --os-beta-command fixes the problem.

There's no need to handle backwards compatibility for the option name
change because there hasn't been an OSC release yet with beta commands.

Change-Id: I0327ba8a2058858a83e9a42e231470ed733cc834
Closes-Bug: #1588384
2016-06-02 10:07:34 -05:00
Jenkins
37bc7bbf91 Merge "Add network segment command object" 2016-05-30 06:20:21 +00:00
Jenkins
d532e3b5f2 Merge "Add "image unset" command" 2016-05-30 04:39:34 +00:00
Jenkins
1dfc7d4b94 Merge "Fix functest "test_server_metadata()" in test_sever.py" 2016-05-30 03:29:14 +00:00
sunyajing
3e11661074 Add "image unset" command
This patch add a command that supports
unsetting image tags and properties

Change-Id: I6f2cf45a61ff89da6664f3a34ae49fdd85d8c986
Closes-Bug:#1582968
2016-05-28 16:38:22 +08:00
Huanxuan Ao
366adf98c0 Fix functest "test_server_metadata()" in test_sever.py
There is only a functional test for "server set" command
in test_server_metadata(), we also need a functional test
for "server unset" command, so I add it in this patch.

Change-Id: I23c40ac1c5adcc2563d8aa9dcb5551df695e98e3
2016-05-28 13:32:13 +08:00
Richard Theis
6a55e05cbf Add network segment command object
Add network segment command object in support of routed networks.
This patch set includes documentation, unit tests and functional
tests (currently skipped until segments enabled in neutron by
default) for the following new commands:
  - "os network segment list"
  - "os network segment show"

These new commands are currently marked as beta commands.

Change-Id: I1a79b48dc6820fe2a39fcceb11c8cae3bda413a0
Partially-Implements: blueprint routed-networks
2016-05-27 12:58:25 -05:00
Jenkins
062d57ff62 Merge "Add some functional tests for commands in VolumeV2" 2016-05-23 20:32:30 +00:00
Jenkins
59f8e32674 Merge "Add network support for "quota set"" 2016-05-23 20:13:35 +00:00
Huanxuan Ao
4d44a3c13f Add some functional tests for commands in VolumeV2
VolumeV2 lacked functional tests for qos specs
and volume type commands, so I add them.
These tests are quite similar to those in v1,just
three difference:
1.Importing functional.common.test instead of
functional.tests.volume.v1.common
2.Adding test_volume_type_set_unset_project()
in test_volume_type.py.
3.Adding a test for "qos unset" command in
test_qos.py

Change-Id: Ic50e8c49ef01ac967c01ec41fb3f04cd51fea9e4
2016-05-23 12:19:49 +08:00
Huanxuan Ao
e10a5979bc Add functional tests for server group in ComputeV2
Change-Id: I43a6ce3a6d976f3d1bd68c0483c929977b660f0d
2016-05-21 16:06:17 +08:00
Fang Zhen
b92cf77fb5 Add network support for "quota set"
The "quota set" command support compute and volume quotas previously.
This patch add support network.

Partially-implements: blueprint neutron-client-quota
Closes-bug: 1489441

Change-Id: I9d297f52bc30614b3493f09ed15f8f1d3f8ff952
2016-05-19 20:42:59 +08:00
Richard Theis
fd5fd924d1 Additional network protocol support
Add the following network protocol support to the
"os security group rule create" command:
  - Add "--icmp-type" and "--icmp-code" options
    for Network v2 only. These options can be used to set
    the ICMP type and code for ICMP IP protocols.
  - Change the "--proto" option to "--protocol". Using the
    "--proto" option is still supported, but is no longer
    documented and may be deprecated in a future release.
  - Add the following Network v2 IP protocols to the
    "--protocol" option: "ah", "dccp", "egp", "esp", "gre",
    "igmp", "ipv6-encap", "ipv6-frag", "ipv6-icmp",
    "ipv6-nonxt", "ipv6-opts", "ipv6-route", "ospf", "pgm",
    "rsvp", "sctp", "udplite", "vrrp" and integer
    representations [0-255].

The "os security group rule list" command now supports
displaying the ICMP type and code for security group rules
with the ICMP IP protocols.

Change-Id: Ic84bc92bc7aa5ac08f6ef91660eb6c125a200eb3
Closes-Bug: #1519512
Implements: blueprint neutron-client
2016-05-14 07:54:41 -05:00
Jenkins
8632c93d24 Merge "Fix functional test for floatingip add/remove in ComputeV2" 2016-05-11 09:04:20 +00:00
Jenkins
fe02162bd3 Merge "Implement "address scope set" command" 2016-05-11 07:59:04 +00:00
Huanxuan Ao
0e0f314e2e Fix functional test for floatingip add/remove in ComputeV2
Updata test_server_attach_detach_floating_ip in test_server.py

Change-Id: I2963991dfafbb17431b44e2f37bb26fa4daac9aa
2016-05-11 14:58:52 +08:00
Huanxuan Ao
cc78d48a28 Implement "address scope set" command
This patch add a command that supports
setting address scope properties.

Change-Id: I9c4b5068a8abb986a9dc18b167b48b924d16ff42
Closes-Bug: #1566269
2016-05-11 10:08:47 +08:00
Richard Theis
c1dba6ab1b Fix functional test failures
There have been a lot of functional test failures for compute
and network.  I believe they are timing related in that the
test_server is sometimes booting a server with a flavor,
image and/or network created by another functional test. Such
resources are then deleted by the owning functional tests
causing various types of failures

Change-Id: Ib82edd487da46610374fb0eb5796cb98f2d3aa2c
2016-05-07 10:38:01 -05:00
Steve Martinelli
461a203f2d bump timeout to prevent gate failures
attempt to fix the transient gate failures by increasing the
timeout

Change-Id: I837652013f94b0d1ed3f4b40fe14ce5a47c687b6
2016-05-05 09:19:41 -07:00
Jenkins
4d85a3f0c6 Merge "Add functional tests for commands of floating ip" 2016-05-05 07:11:59 +00:00
Daniel Gonzalez
9ec41c0397 Replace tempest-lib with tempest.lib
tempest-lib is deprecated, so replace it with tempest.lib.

Co-Authored-By: Sheel Rana <ranasheel2000@gmail.com>

Change-Id: I0495eba110bb7581623fbcf49dc63a27e9cb6d64
Closes-Bug: #1553047
2016-04-29 08:33:45 +00:00
Huanxuan Ao
9dba843bde Add functional tests for commands of floating ip
This patch add functinal tests for commands of floating ip

Change-Id: I7f29578d0e14884f21183bfb82228d2fe7b7a029
2016-04-28 15:19:16 +08:00
Richard Theis
27024d70af Support quota show for current project
The "os quota show" command "<project/class>" argument is now
optional. If not specified, the user's current project is used.
This allows non-admin users to show quotas for their current
project.

Change-Id: I602d4cc09c9d29ce84271eff78137f8810cb1a47
Closes-Bug: #1572733
2016-04-21 11:33:24 -05:00
Jenkins
98a0fba3c1 Merge "Update keypair tests" 2016-04-20 19:40:44 +00:00
Jenkins
eb522fbb5e Merge "Update tests for server" 2016-04-20 16:11:39 +00:00
Kyrylo Romanenko
0e8c78c91a Update tests for server
Make testcases separate instances of test class.
Use setUp with addCleanup methods for every test case.
Add more descriptive docstrings for tests.

Closes-Bug: #1483422
Partial-Bug: #1566962
Change-Id: I1a16b5bad1dafd19fd7dc94794c0bd4587b7f516
2016-04-20 05:20:13 +00:00
Kyrylo Romanenko
ff62c832b5 Update keypair tests
Make testcases separate instances of test class.
Use setUp with addCleanup methods for every test case.
Add negative test cases.

Closes-Bug: #1564480
Change-Id: I5d8fd2a238e6cf0584777eb0d24dfcaed4133ee1
2016-04-19 15:10:30 +03:00
Jirayut Nimsaeng
e128370676 Fix wrong attribute name and add functional test for --snapshot
Change-Id: I91f2091ef06a55bcf5373d1beeea2dd81e9f1334
Closes-Bug: #1567895
2016-04-15 16:13:02 +00:00
Jenkins
ef68f23de3 Merge "Add network options to security group rule create" 2016-04-14 19:55:54 +00:00
Jenkins
e1305185d3 Merge "Prefer assertEqual/assertIn over assertOutput/assertInOutput" 2016-04-14 19:55:26 +00:00
Kyrylo Romanenko
573bb6b941 Use CommandFailed exception from tempest_lib
Remove exceptions.py from functional/common.
Import exception with the same code from the tempest_lib to tests.

Change-Id: Ifaa658209c18dd608836079f57ed18fcf10fb84e
2016-04-13 19:09:07 +03:00
Richard Theis
3a3f33b926 Add network options to security group rule create
Add the following network options to the "os security group rule"
command:
  (1) --ingress and --egress
  (2) --ethertype
These options enable egress and IPv6 security group rules for
Network v2.

Change-Id: Ie30b5e95f94e0c087b0ce81e518de72d2dda25ad
Partial-Bug: #1519512
Implements: blueprint neutron-client
2016-04-11 09:49:21 -05:00
Jenkins
870fa2f2a2 Merge "Correct addCleanup use in functests" 2016-04-07 16:32:07 +00:00
Cedric Brandily
b13ec98467 Prefer assertEqual/assertIn over assertOutput/assertInOutput
functional.common.tests module defines:

 * assertOutput (similar to assertEqual)
 * assertInOutput (similar to assertIn)

in order to allow the usage of assertions in testcase classmethods but
there is no reason to use them in testcase instancemethods at least
because they raise Exception instances instead of AssertionError
instances.

Change-Id: I9ffcaf9c6e6a1ff5df6ea2d79be3fb4496db4b85
2016-04-06 20:59:59 +02:00
Cedric Brandily
e2e9c49cd9 Correct addCleanup use in functests
This change replaces in many identity functests the pattern:

 raw_resource = create_resource(...)
 check(raw_resource)
 self.addCleanup(delete_resource, ...)
 ...

by the pattern:

 raw_resource = create_resource(...)
 self.addCleanup(delete_resource, ...)
 check(raw_resource)
 ...

which ensures that cleanup is defined and called after the test even if
check(resource) fails.

Change-Id: I4da541b7552d06eaffafda446e389bb552422cda
2016-04-06 20:43:21 +02:00
Cedric Brandily
3c82c0e62e Improve tmpfile cleanup in functests
This change replaces when possible homemade temporary file management by
tempfile.NamedTemporaryFile[1][2] and defines only when needed a cleanup
for a temporary file[2].

[1] functional/tests/compute/v2/test_keypair.py
[2] functional/tests/object/v1/test_object.py

Change-Id: I728ab96381ca9f3fd1f899dd50e5ceb5e97b9397
2016-04-06 00:40:44 +02:00
Jenkins
f48f9398b8 Merge "Add fixed keypair create functional test" 2016-03-31 02:47:00 +00:00
Dean Troyer
029654b9a8 Add fixed keypair create functional test
This adds a test case to exercise the --public-key option of
the 'keypair create' command.  It is a follow-on to
I7a299a542d9df543bff43d3ea1e7907fc8c5f640 that fixed a key file
read bug.

Change-Id: Id78c1c7ece02f619aca69dc397185fc426b92306
2016-03-30 15:58:42 -05:00
Jenkins
0a760e2d87 Merge "Added functional tests for 'service provider' v3 commands" 2016-03-28 20:54:59 +00:00
Kristi Nikolla
add0e10026 Added functional tests for 'service provider' v3 commands
'identity provider' commands had functional tests but 'service
provider' commands did not. Added the tests in a similar way to
how it is done it test_idp.

Change-Id: Id4b24ef7d34db65c6b0260c89327ec9be683284d
2016-03-28 10:06:35 -04:00
Jenkins
ef1faf7792 Merge "Subnet: Add "subnet set" command using SDK" 2016-03-25 15:47:15 +00:00
reedip
2b95e363d3 Subnet: Add "subnet set" command using SDK
This patch adds "subnet set" command to osc using sdk.

Implements: blueprint neutron-client

Closes-bug: #1542363

Change-Id: Id3b7f4b9190b4d73ca3ae423321a65f94a6da62e
2016-03-24 02:21:40 +00:00
Jenkins
98dc781e94 Merge "Remove superfluous variable assignment statements" 2016-03-21 21:33:06 +00:00
Kyrylo Romanenko
526f2f9f77 Remove superfluous variable assignment statements
wait and interval are already defaulted in the function signature

Change-Id: I66317a24f8327c464343ac13fc0126c34915eeda
2016-03-21 19:32:11 +00:00
Kyrylo Romanenko
0a65e8df70 Style fix for one line docstring according to flake8
Change-Id: I639819a5b1d8a476cdd8b340b8c339754f471048
2016-03-21 18:32:44 +02:00
Kyrylo Romanenko
89182c4825 Functional tests for openstackclient help messages
Add tests for list and description for Server commands:
 - Check server commands in main help message.
 - Check list of server-related commands only.
Commands:
  server add security group,
  server add volume,
  server create,
  server delete,
  server dump create,
  server image create,
  server list,
  server lock,
  server migrate,
  server pause,
  server reboot,
  server rebuild,
  server remove security group,
  server remove volume,
  server rescue,
  server resize,
  server resume,
  server set,
  server shelve,
  server show,
  server ssh,
  server start,
  server stop,
  server suspend,
  server unlock,
  server unpause,
  server unrescue,
  server unset,
  server unshelve.

Change-Id: Ib4bf9ab0264fb482d36cf5688c0f939bcd2cb6d8
2016-03-18 18:28:24 +02:00
Jenkins
9447a0e2c7 Merge "Add subnet functional tests" 2016-03-14 16:10:03 +00:00
Jenkins
4bb48c088d Merge "Add subnet pool functional tests" 2016-03-10 00:38:33 +00:00
Richard Theis
87d90f3e53 Add subnet pool functional tests
Add functional tests for "os subnet pool" commands.

Change-Id: I51ffabcdb4d0f8608cc847aae298c8cbfd1f6a3d
Depends-On: I9150797c8cfa794d5264ad07965aa967d9a8f5bc
Depends-On: I65bd71e0f54f2f65acefbc542df67a1b1ec26397
Related-Bug: #1544586
Related-Bug: #1544587
Related-Bug: #1544589
Related-Bug: #1544590
Related-Bug: #1544591
Partially-Implements: blueprint neutron-client
2016-03-09 11:30:06 -06:00