Commit Graph

19 Commits

Author SHA1 Message Date
zhurong 1ea1cda5d4 Remove murano_tempest_tests from murano repo
Change-Id: I5da1c660393df335f8d5e8ab17b23bb21a8e3257
2017-12-07 02:03:48 +00:00
Andrea Frittoli 12beb64c78 Handle available volume client versions
If Cinder is not available or Cinder v1 only is available skip
volume attachment tests. Else prefer volume v3 where available
or fallback to v2 otherwise.

This requires a Tempest patch for the snapshots v3 client.

Change-Id: If3b6a2c71498c19a0a8dfeb4c51e2c80e5a918f4
Depends-on: I21f07f7b3e8f22055e7978c0bf4aa01b80b493d9
2017-07-28 23:58:43 +01:00
Jenkins 5df983c181 Merge "Make cinder volume attachments available" 2017-07-19 15:03:45 +00:00
zhurong e667abdb84 Make cinder volume attachments available
This commit is revert from Ib996bf50e1b7d542b98cf9d7125b824771c143d6,

Change-Id: Ie866833d205c119254b811654426c586c338d7c8
Closes-Bug: #1703387
2017-07-19 09:21:58 +08:00
Andrea Frittoli f2f057c3f3 Init the orchestration client from config (part2)
Tempest will not be initialising the orchestration client by default
anymore since Heat is not a service hosted in Tempest (for a long time now).
The client is still available in Tempest (as long as it's not made
available by heat somewhere else), so to use it it's enough to pass it's
configuration to it.

This was partly fixed in Ic6fef4b4f260d13efd7b035bc012369f0da55602 but
the patch was not complete.

Change-Id: Iba1680276fec776a81f1e91fd591137e39bf6d07
2017-07-18 21:19:39 +01:00
Andrea Frittoli 60eb9ed60f Init the orchestration client from config
Tempest will not be initialising the orchestration client by default
anymore since Heat is not a service hosted in Tempest (for a long time now).
The client is still available in Tempest (as long as it's not made
available by heat somewhere else), so to use it it's enough to pass it's
configuration to it.

Change-Id: Ic6fef4b4f260d13efd7b035bc012369f0da55602
2017-07-17 16:19:36 +01:00
zhurong 0c42290126 Unskip test_deploy_app_with_volume_creation test
1.Unskip test_deploy_app_with_volume_creation test
2.change flavor from m1.small to m1.tiny, to reduce the
test failing chances.

Closes-Bug: #1701230

Change-Id: Ib996bf50e1b7d542b98cf9d7125b824771c143d6
2017-07-07 08:34:23 +00:00
Felipe Monteiro 2e8137af5e Use tempest.test.BaseTestCase for murano tempest tests
While Tempest's own plugin documentation recommends that
plugins only consume tempest.lib [0], the BaseTestCase in
tempest.test is more feature-rich, comprehensive, and fault-tolerant
than the BaseTestCase in tempest.lib.

Many plugins like keystone_tempest_plugin already use the
BaseTestCase in tempest.test. Also, QA PTL said it would be
fine to make the transition when asked in IRC [1][2].

This commit specifically:
  - uses the base tempest class pattern specified in
    `tempest.test.BaseTestCase`: skip_checks for skipping tests based
    on environment config settings; setup_clients for instantiating
    clients and client managers; resource_setup for setting up
    class-level resources; and resource_cleanup for cleaning up
    class-level resources
  - removes unusued helpers like verify_nonempty, except in classes
    that explicitly already use it
  - removes clearing credentials in tearDown because the code isn't
    even executed due to a bug introduced by
    I51434685555c1da92401891a60285bf52571b8b5
  - separate admin clients from non-admin clients by using os_admin
    vs os_primary

[0] https://docs.openstack.org/developer/tempest/plugin.html#plugin-structure
[1] http://eavesdrop.openstack.org/irclogs/%23openstack-qa/%23openstack-qa.2017-06-12.log.html#t2017-06-12T20:38:19
[2] http://eavesdrop.openstack.org/irclogs/%23openstack-qa/%23openstack-qa.2017-06-12.log.html#t2017-06-12T21:45:56

Change-Id: Ia09dbc52ba13ca822a539e509e0e517592435aec
2017-06-17 16:13:51 +01:00
Jenkins 5354a3b553 Merge "Stop using aliases for creds manager" 2017-05-10 19:50:05 +00:00
Paul Bourke 103f67815a Allow users to assign a security group to an app
This patch allows users to supply a list* of their own security groups to
an instance, rather than using the application defined one (built via
the SecurityGroupManager).

* Note, while we can support multiple security groups, murano-dashboard
currently has no UI element to select multiple items. This means that
currently users are restricted to selecting one group. If/when the
UI is improved this change can easily support multiple groups.

Example
=======

Application authors can make this available in their apps as follows:

UI.yaml
-------
Forms:
  - instanceConfiguration:
      fields:
          ...
        - name: securityGroups
          type: securitygroup
          label: Security Group
          required: false

Class.yaml:
----------
  Application:
    ?:
       type: com.paul.HelloWorld
    instance:
      ?:
        type: io.murano.resources.LinuxMuranoInstance
      name: $.instanceConfiguration.hostname
      securityGroups: $.instanceConfiguration.securityGroups
      ...

DocImpact
Change-Id: I60d37cfe034c467e894ee93cf3718e463bf49337
Partially-Implements: blueprint app-use-existing-security-group
2017-04-27 17:37:20 +01:00
Felipe Monteiro 050be0b96a Stop using aliases for creds manager
Now that Tempest has stopped using aliases like cls.os
and cls.os_adm [0], Murano should do the same.

This patch normalizes the usage around os_admin, os_primary and
os_alt.

[0] https://review.openstack.org/#/c/457555/

Change-Id: I40e6cb8eec8e67f4dbe4f92d7216a3b0ebcd4a59
Related-Change-Id: I5f7164f7a7ec5d4380ca22885000caa0183a0bf7
2017-04-27 02:10:35 +01:00
Jenkins 928db440f2 Merge "Make CinderVolume attachment info available" 2017-04-17 09:48:08 +00:00
Paul Bourke 107fc981be Make CinderVolume attachment info available
Make the 'attachments' attribute of OS::Cinder::Volume available in
MuranoPL.

Users can do the following in their applications:

  - For: blockDevice
    In: $this.instance.blockDevices
    Do:
      - For: attachment
        In: $blockDevice.volume.attachments
        Do:
          - $reporter.report($this, attachment.device)
          - $reporter.report($this, attachment.attachment_id)
          ...

Implements: blueprint devicename-from-volume-attachment
Change-Id: I2986efde085dd8029f2520cb5744e75f6a66f282
2017-04-13 10:32:21 +01:00
ol7435 8a3ed3f833 Change cred provider to enforce dynamic config
Current tests always dynamically create accounts when running.

These tests do not run when, for example, LDAP is configured.

This change allows murano_tempest_tests to correctly interpret
use_dynamic_credentials config in the [auth] section of tempest.conf

When use_dynamic_credentials is set to True, dynamic accounts will be created.
When set to false, pre-provisioned accounts specified in
accounts.yaml Tempest config will be used.

Closes-Bug: #1677893
Change-Id: I51434685555c1da92401891a60285bf52571b8b5
2017-04-10 11:30:38 -05:00
Felipe Monteiro 10752e6bba Renames wait_for_volume_status in tempest tests for consistency.
A recent change in Tempest [0] is breaking 2 murano tempest tests;
wait_for_volume_status was changed to wait_for_volume_resource_status,
causing an AttributeError to be thrown [1].

Additionally, a recent change in Cinder [2] removed multiattach
for all drivers, causing one of the murano tempest scenario tests
involving deploying an environment using a multiattach-enabled volume
to fail.

This patch renames the function wait_for_volume_status to be compatible
with the recent Tempest change. It also uses staticmethod delete
functions provided by the Tempest API for delete_volume and
delete_snapshot. It also removes the multiattach property in the
relevant tempest test.

[0] https://review.openstack.org/#/c/394588/29/tempest/common/waiters.py
[1] http://logs.openstack.org/01/435101/2/check/gate-tempest-dsvm-murano-api-ubuntu-xenial/911be71/console.html
[2] https://review.openstack.org/#/c/428365/

Related-Bug: #1668848
Co-Authored-By: ricolin <rico.lin@easystack.cn>
Change-Id: I15ae3f9c931ba606883a22a5af719f79685093a7
2017-03-03 06:25:54 +03:00
Victor Ryzhenkin 8783d53147 Move test with cinder backup creation to the IsolatedAdmin suite
- Move test_deploy_app_with_volume_creation_from_backup to the
IsolatedAdmin test suite
- Make tests using cinder v2 version due tempest defaults
- Unskip test_deploy_app_with_volume_creation_from_backup test

Closes-Bug: #1634876

Change-Id: I8b3ab7f000804f6b368d06ef877776b324774ad4
2016-10-20 16:08:04 +03:00
Victor Ryzhenkin f547dff5c4 Repair cinder integration tests
- Use image from nova scenario tests for cinder tests
- Correct environment status wait function
- Replace backup waiters with new tempest changes
- Use devstack trueorfalse common function to determine
boolean values

Closes-Bug: #1626872

Change-Id: Id2172d3d9b314eb8132d97ec8868028c714a35c3
2016-10-17 16:50:33 +03:00
Aleksandr Kholkin 8501b1872b Refactor 'wait_for_environment_deploy' function
This commit deletes wait_for_environment_deploy function from scenario base
and replaces it with the similar function, declared in utils.

Change-Id: I59216bf728dba154534cec8af31f60ea9a9cdac1
2016-08-17 09:23:56 +00:00
MStolyarenko 36915a927d Add base and packages for tempest murano scenario tests
This commit adds implementation of methods and resources
which are used for tempest app deployment and cinder volumes
support tests

Change-Id: Ibd70aa56987d8f69547fb9f114b6a1a69cfcbe0c
targets: bp normalize-murano-tests
2016-08-03 15:59:59 +03:00