Add ssh check to quantum smoke test.

 * Doing a ping check to verify that a vm is reachable may result
   in a false positive if the target ip is routed in error to a
   nonetheless pingable host.  This patch adds an ssh check that will
   fail if the target is not configured with the expected (and
   dynamically generated) ssh keypair.
 * Adding the ssh check uncovered a bug in security group creation -
   source group rules were being used that restricted traffic to
   ports associated with the security group.  This is now fixed.
 * Addresses bug 1182343

Conflicts:
	tempest/scenario/manager.py
	tempest/scenario/test_network_basic_ops.py

Change-Id: I4112ad9a8854fc113d5fefc7ea03a55da7d0ed1b
(cherry picked from commit af292e8eb7c5318541eb6e88ccde7d5b7c00cb71)
Fix AttachInterfacesTest error

This commit fixes some issues in AttachInterfacesTest.
* There is a problem to get the return value, TypeError is
  occurring.
* Assign the JSON or XML to _interface, but it is not specified
  in the method.
* Add a process to wait until the "ACTIVE" status.
  Because the status is "DOWN" when a interface is created.

Fixes bug 1164894

Change-Id: I71ec9e46eb15e70f870b7a833d5433fa351c42eb
(cherry picked from commit ba9e909dfb8983fc9fd51f7d79b772d03abfe3b0)
Skip cli-keystone catalog and help tests

Skip those two tests until Bug #1213912 is solved,
as it freezed all stable/grizzly checks.

Change-Id: I0a7b22f3212d79705f922e8bcabd29be365123a2
cli: add messages to assertTrue

1) Unify assertion of 'usage: service-name' from
   {cinder, glance, keystone, neutron} help tests
   into assertFirstLineStartsWith method, which provides
   more usefull failure message.
2) Add failure message to assertTrue in keystone-catalog
   test.

(cherry picked from commit 4c18fa1bbf85e3e8d0352b45a6f235afaeea4081)

Conflicts:
	cli/__init__.py
	tempest/cli/simple_read_only/test_cinder.py
	tempest/cli/simple_read_only/test_glance.py
	tempest/cli/simple_read_only/test_neutron.py

Change-Id: I3abba1d9509bee649aa1675beee4153341b1e170
Merge "Add ssh check to quantum smoke test." into stable/grizzly
Merge "Fix AttachInterfacesTest error" into stable/grizzly
Merge "cli: add messages to assertTrue" into stable/grizzly
Skip secgroup invalid name/desc tests until bug 1161411 is fixed

There is an existing review which tries to deal with bug 1161411:

https://review.openstack.org/#/c/34559/

Until there is consensus on how to fix this, skip the compute tests if
neutron is available.

(cherry picked from commit 6e3454465e343922dd4c977c1e4fd84f257f5650)

Conflicts:
	tempest/tests/compute/security_groups/test_security_groups.py

Change-Id: I41bd2232ad4e489daaa8de3902d7e158f3e577bf
Merge "Skip secgroup invalid name/desc tests until bug 1161411 is fixed" into stable/grizzly
Add a test for creation of volumes' snapshots.

A new test called 'test_snapshot_create_get_delete' is added.
Also adds setUpClass and tearDownClass methods to create a
shareable volume origin.
Finally updates the existing 'test_volume_from_snapshot' which
now uses the create_* and clear_* wrappers from base class and
the shareable volume origin from setUpClass method.

Change-Id: I3fb8edabaf4649736a43d6de5a9c4518d3caac62
Implements: blueprint add-snapshot-tests
(cherry picked from commit 7333293fb549cb88a26246ddcd2f0c6bc812ce74)
Skip test that is not relevant to Quantum

Quantum allows duplicate names for security groups,
thus this test must be skipped.

bug #1194468

(cherry picked from commit 30d6ae7a317a38a78c7db88e33834f5541175221)

Conflicts:
	tempest/tests/compute/security_groups/test_security_groups.py

Change-Id: Ic54e5b4b7f7d95a0a6db568fb9a66a566a101fc9
Skip secgroup rules invalid id tests until bug 1182384 is fixed

There are some existing reviews which try to deal with bug 1182384:

nova: https://review.openstack.org/#/c/35285/

tempest: https://review.openstack.org/#/c/29899/

There is also a mailing list discussion about this (see the link in the
bug report).

Until there is consensus on how to fix this, skip the compute tests if
neutron is available.

(cherry picked from commit 1d3f88580cee74ee127dac8b854dc545c04c28eb)

Conflicts:
	tempest/tests/compute/security_groups/test_security_group_rules.py

Change-Id: I3f0d21c23661f556354c321476ba559d4925dccd
Merge "Skip secgroup rules invalid id tests until bug 1182384 is fixed" into stable/grizzly
Always log stdout and stderr of CLI commands

Currently it was logged only when cli subprocess call itself
failed, so there was not enough debug output when asserts/test cases
failed.

Also fixes invalid log.warning on newline at the end of ascii table.

For backport - as stderr was always merged to stdout in grizzly time
 - corresponding parts of the patch were removed.

(cherry picked from commit 0d9a84fb614fc65fa4417d1103d051a9580555df)

Conflicts:
	cli/__init__.py

Change-Id: I5251a06018e8bf79c30ad84f8f0ed8aac797f832
Add venv tox environment for taball generation

The jenkins job for creating a sdist tarball uses
tox -evenv, which was missing here.

Change-Id: I864605d6b8e7bd362e2e77eb8d9e5806283c2116
Fixes: Bug #1202978
Add Manifest in order to include AUTHORS and ChangeLog

Unlike in master, where a different method for creating the
sdist tarball is used, we still need a MANIFEST.in here for
including AUTHORS and ChangeLog in the tarball.

Change-Id: I266b04048c383b4f127d336411937b102bfafab3
Fixes: Bug #979958
Merge "Add a test for creation of volumes' snapshots." into stable/grizzly
Use nose skip exception conditionally

testtools and nose disagree on the exception raised for skipping
tests with python < 2.7 (see inline comments for exact details).

This monkey-patches testtools to recognise the nose skip exception.
However, due to nose being deprecated we hide this behind an
environment variable to make it an opt-in fix.

While we're there, modify tempest.test.api.utils @skip_unless_attr
decorator to raise from tempest's BaseTestCase rather than
testtools.TestCase directly.

Conflicts:
	tempest/test.py

Change-Id: I13a8f374e879799870bc9193a1ddbdc8d6abb73c
(cherry picked from commit 98c35f3b430e2b364c1650c08154ce969626af38)
Unskip cli-keystone catalog and help tests

Unskip tests which were skipped before pinning python-keyring to
not-faulty version as per bug 1193164.

This reverts commit 27e8547c31f15708b3ff143a62eb96742b287d26.

Change-Id: I1c4c4a509f4629eb8aeb1963e1c9623338d65453
Merge "Add Manifest in order to include AUTHORS and ChangeLog" into stable/grizzly