summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexandru Muresan <amuresan@cloudbasesolutions.com>2017-08-08 13:30:22 +0300
committerClaudiu Belu <cbelu@cloudbasesolutions.com>2017-08-09 16:50:53 +0000
commitb3f383b62b692183f025d7c6fde5ea00b735f8db (patch)
tree65a76c1fc42d48a12be4b03346c9662117eb535e
parentddc4157b333ef6357fd89b7a577ccd99cc7bdd2e (diff)
Add RemoteFX optional feature test
This test checks if RemoteFX feature can be turned on or off. Co-Authored-By: Claudiu Belu <cbelu@cloudbasesolutions.com> Change-Id: I2fbab9e43a577c5a6509df8fcca7a71de8806ad1
Notes
Notes (review): Code-Review+2: Claudiu Belu <cbelu@cloudbasesolutions.com> Workflow+1: Claudiu Belu <cbelu@cloudbasesolutions.com> Verified+2: Jenkins Submitted-by: Jenkins Submitted-at: Wed, 09 Aug 2017 20:38:33 +0000 Reviewed-on: https://review.openstack.org/491748 Project: openstack/oswin-tempest-plugin Branch: refs/heads/master
-rw-r--r--oswin_tempest_plugin/config.py4
-rw-r--r--oswin_tempest_plugin/tests/scenario/test_remotefx.py44
2 files changed, 48 insertions, 0 deletions
diff --git a/oswin_tempest_plugin/config.py b/oswin_tempest_plugin/config.py
index 8870636..4ac2d6e 100644
--- a/oswin_tempest_plugin/config.py
+++ b/oswin_tempest_plugin/config.py
@@ -52,6 +52,10 @@ HyperVGroup = [
52 cfg.IntOpt('failover_sleep_interval', 52 cfg.IntOpt('failover_sleep_interval',
53 default=5, 53 default=5,
54 help='The amount of time to wait between failover checks.'), 54 help='The amount of time to wait between failover checks.'),
55 cfg.BoolOpt('remotefx_enabled',
56 default=False,
57 help="RemoteFX feature is enabled and supported on the "
58 "compute nodes."),
55] 59]
56 60
57 61
diff --git a/oswin_tempest_plugin/tests/scenario/test_remotefx.py b/oswin_tempest_plugin/tests/scenario/test_remotefx.py
new file mode 100644
index 0000000..5834d21
--- /dev/null
+++ b/oswin_tempest_plugin/tests/scenario/test_remotefx.py
@@ -0,0 +1,44 @@
1# Copyright 2017 Cloudbase Solutions SRL
2# All Rights Reserved.
3#
4# Licensed under the Apache License, Version 2.0 (the "License"); you may
5# not use this file except in compliance with the License. You may obtain
6# a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13# License for the specific language governing permissions and limitations
14# under the License.
15
16from oswin_tempest_plugin import config
17from oswin_tempest_plugin.tests._mixins import optional_feature
18from oswin_tempest_plugin.tests import test_base
19
20CONF = config.CONF
21
22
23class RemoteFxTestCase(test_base.TestBase,
24 optional_feature._OptionalFeatureMixin):
25 """RemoteFX test suite.
26
27 This test suit will spawn instances with RemoteFX enabled.
28 """
29
30 # RemoteFX is supported in Windows / Hyper-V Server 2012 R2 and newer.
31 _MIN_HYPERV_VERSION = 6003
32
33 _FEATURE_FLAVOR = {'extra_specs': {'os_resolution': '1920x1200',
34 'os_monitors': '1',
35 'os_vram': '1024'}}
36
37 @classmethod
38 def skip_checks(cls):
39 super(RemoteFxTestCase, cls).skip_checks()
40 # the CONF.hyperv.remotefx_enabled config option needs to be enabled.
41 if not CONF.hyperv.remotefx_enabled:
42 msg = ('The config option "hyperv.remotefx_enabled" is False. '
43 'Skipping.')
44 raise cls.skipException(msg)