Remove deprecated feature modules 49/33349/2
authorCédric Ollivier <cedric.ollivier@orange.com>
Thu, 13 Apr 2017 14:52:16 +0000 (16:52 +0200)
committerCédric Ollivier <cedric.ollivier@orange.com>
Fri, 14 Apr 2017 06:57:36 +0000 (08:57 +0200)
All features running bash programs are now simply defined in
testcases.yaml. All deprecated modules and unit tests are removed.

Change-Id: I7047b6f7a1e43cb8ed5ba2d569d5dcecae68fb86
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
23 files changed:
functest/ci/testcases.yaml
functest/core/feature.py
functest/opnfv_tests/features/copper.py [deleted file]
functest/opnfv_tests/features/doctor.py [deleted file]
functest/opnfv_tests/features/domino.py [deleted file]
functest/opnfv_tests/features/netready.py [deleted file]
functest/opnfv_tests/features/odl_sfc.py [deleted file]
functest/opnfv_tests/features/promise.py [deleted file]
functest/opnfv_tests/features/sdnvpn.py [deleted file]
functest/opnfv_tests/features/security_scan.py [deleted file]
functest/opnfv_tests/vnf/rnc/__init__.py [deleted file]
functest/opnfv_tests/vnf/rnc/parser.py [deleted file]
functest/tests/unit/core/test_feature.py
functest/tests/unit/features/test_copper.py [deleted file]
functest/tests/unit/features/test_doctor.py [deleted file]
functest/tests/unit/features/test_domino.py [deleted file]
functest/tests/unit/features/test_netready.py [deleted file]
functest/tests/unit/features/test_odl_sfc.py [deleted file]
functest/tests/unit/features/test_promise.py [deleted file]
functest/tests/unit/features/test_sdnvpn.py [deleted file]
functest/tests/unit/features/test_security_scan.py [deleted file]
functest/tests/unit/vnf/rnc/test_parser.py [deleted file]
run_unit_tests.sh

index f717cdd..febe157 100755 (executable)
@@ -276,8 +276,10 @@ tiers:
                     installer: '(fuel)|(joid)'
                     scenario: ''
                 run:
-                     module: 'functest.opnfv_tests.features.promise'
-                     class: 'Promise'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/promise/promise/test/functest && python ./run_tests.py'
 
             -
                 case_name: doctor-notification
@@ -291,8 +293,10 @@ tiers:
                     installer: '(apex)|(fuel)'
                     scenario: '^((?!fdio).)*$'
                 run:
-                    module: 'functest.opnfv_tests.features.doctor'
-                    class: 'Doctor'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/doctor/tests && ./run.sh'
 
             -
                 case_name: bgpvpn
@@ -306,8 +310,10 @@ tiers:
                     installer: '(fuel)|(apex)|(netvirt)'
                     scenario: 'bgpvpn'
                 run:
-                    module: 'functest.opnfv_tests.features.sdnvpn'
-                    class: 'SdnVpnTests'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/sdnvpn/sdnvpn/test/functest && python ./run_tests.py'
 
             -
                 case_name: security_scan
@@ -321,8 +327,10 @@ tiers:
                     installer: 'apex'
                     scenario: '^((?!fdio).)*$'
                 run:
-                    module: 'functest.opnfv_tests.features.security_scan'
-                    class: 'SecurityScan'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: '. /home/opnfv/functest/conf/stackrc && cd /home/opnfv/repos/securityscanning && python security_scan.py --config config.ini && cd -'
 
             -
                 case_name: multisite
@@ -350,8 +358,10 @@ tiers:
                     installer: '(apex)|(fuel)'
                     scenario: 'odl_l2-sfc'
                 run:
-                    module: 'functest.opnfv_tests.features.odl_sfc'
-                    class: 'OpenDaylightSFC'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/sfc/sfc/tests/functest && python ./run_tests.py'
             -
                 case_name: onos_sfc
                 project_name: functest
@@ -378,8 +388,10 @@ tiers:
                     installer: 'fuel'
                     scenario: '^((?!bgpvpn|noha).)*$'
                 run:
-                    module: 'functest.opnfv_tests.vnf.rnc.parser'
-                    class: 'Parser'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/parser/tests && ./functest_run.sh'
             -
                 case_name: domino-multinode
                 project_name: domino
@@ -392,8 +404,10 @@ tiers:
                     installer: ''
                     scenario: ''
                 run:
-                    module: 'functest.opnfv_tests.features.domino'
-                    class: 'Domino'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/domino && ./tests/run_multinode.sh'
             -
                 case_name: gluon_vping
                 project_name: netready
@@ -406,8 +420,10 @@ tiers:
                     installer: 'apex'
                     scenario: 'gluon'
                 run:
-                     module: 'functest.opnfv_tests.features.netready'
-                     class: 'GluonVping'
+                    module: 'functest.core.feature'
+                    class: 'BashFeature'
+                    args:
+                        cmd: 'cd /home/opnfv/repos/netready/test/functest && python ./gluon-test-suite.py'
             -
                 case_name: barometercollectd
                 project_name: barometer
index 29e0e92..3c95bda 100644 (file)
@@ -1,3 +1,5 @@
+#!/usr/bin/env python
+
 import time
 
 import functest.core.testcase as base
@@ -16,6 +18,7 @@ class Feature(base.TestCase):
         self.logger = ft_logger.Logger(self.project_name).getLogger()
 
     def execute(self, **kwargs):
+        # pylint: disable=unused-argument,no-self-use
         return -1
 
     def run(self, **kwargs):
@@ -23,7 +26,7 @@ class Feature(base.TestCase):
         exit_code = base.TestCase.EX_RUN_ERROR
         self.criteria = "FAIL"
         try:
-            if self.execute() == 0:
+            if self.execute(**kwargs) == 0:
                 exit_code = base.TestCase.EX_OK
                 self.criteria = 'PASS'
             ft_utils.logger_test_results(
@@ -40,5 +43,12 @@ class Feature(base.TestCase):
 class BashFeature(Feature):
 
     def execute(self, **kwargs):
-        return ft_utils.execute_command(
-            self.cmd, output_file=self.result_file)
+        ret = -1
+        try:
+            cmd = kwargs["cmd"]
+            ret = ft_utils.execute_command(cmd, output_file=self.result_file)
+        except KeyError:
+            self.logger.error("Please give cmd as arg. kwargs: %s", kwargs)
+        except Exception:  # pylint: disable=broad-except
+            self.logger.exception("Execute cmd: %s failed", cmd)
+        return ret
diff --git a/functest/opnfv_tests/features/copper.py b/functest/opnfv_tests/features/copper.py
deleted file mode 100644 (file)
index 2c5459f..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright 2016 AT&T Intellectual Property, Inc
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class Copper(base.BashFeature):
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_copper')
-        kwargs["cmd"] = 'cd %s/tests && bash run.sh && cd -' % repo
-        super(Copper, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/doctor.py b/functest/opnfv_tests/features/doctor.py
deleted file mode 100644 (file)
index 0e39248..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright (c) 2017 All rights reserved
-# This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# 0.1: This script boots the VM1 and allocates IP address from Nova
-# Later, the VM2 boots then execute cloud-init to ping VM1.
-# After successful ping, both the VMs are deleted.
-# 0.2: measure test duration and publish results under json format
-#
-#
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class Doctor(base.BashFeature):
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_doctor')
-        kwargs["cmd"] = 'cd %s/tests && ./run.sh' % repo
-        super(Doctor, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/domino.py b/functest/opnfv_tests/features/domino.py
deleted file mode 100644 (file)
index b5def3f..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright (c) 2015 All rights reserved
-# This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# 0.1: This script boots the VM1 and allocates IP address from Nova
-# Later, the VM2 boots then execute cloud-init to ping VM1.
-# After successful ping, both the VMs are deleted.
-# 0.2: measure test duration and publish results under json format
-# 0.3: add report flag to push results when needed
-# 0.4: refactoring to match Test abstraction class
-
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class Domino(base.BashFeature):
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_domino')
-        kwargs["cmd"] = 'cd %s && ./tests/run_multinode.sh' % repo
-        super(Domino, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/netready.py b/functest/opnfv_tests/features/netready.py
deleted file mode 100644 (file)
index 717a4a3..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/usr/bin/python
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-
-#
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class GluonVping(base.BashFeature):
-
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_netready')
-        dir_netready_functest = '{}/test/functest'.format(repo)
-        kwargs["cmd"] = ('cd %s && python ./gluon-test-suite.py' %
-                         dir_netready_functest)
-        super(GluonVping, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/odl_sfc.py b/functest/opnfv_tests/features/odl_sfc.py
deleted file mode 100644 (file)
index f5ecf73..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright (c) 2016 All rights reserved
-# This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class OpenDaylightSFC(base.BashFeature):
-
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_sfc')
-        dir_sfc_functest = '{}/sfc/tests/functest'.format(repo)
-        kwargs["cmd"] = 'cd %s && python ./run_tests.py' % dir_sfc_functest
-        super(OpenDaylightSFC, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/promise.py b/functest/opnfv_tests/features/promise.py
deleted file mode 100644 (file)
index b9e128f..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/usr/bin/python
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class Promise(base.BashFeature):
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_promise')
-        dir_promise_functest = '{}/promise/test/functest'.format(repo)
-        kwargs["cmd"] = 'cd %s && python ./run_tests.py' % dir_promise_functest
-        super(Promise, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/sdnvpn.py b/functest/opnfv_tests/features/sdnvpn.py
deleted file mode 100644 (file)
index 10a97e9..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright (c) 2016 All rights reserved
-# This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class SdnVpnTests(base.BashFeature):
-
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_sdnvpn')
-        dir_sfc_functest = '{}/sdnvpn/test/functest'.format(repo)
-        kwargs["cmd"] = 'cd %s && python ./run_tests.py' % dir_sfc_functest
-        super(SdnVpnTests, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/features/security_scan.py b/functest/opnfv_tests/features/security_scan.py
deleted file mode 100644 (file)
index 8f16725..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright (c) 2015 All rights reserved
-# This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class SecurityScan(base.BashFeature):
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_securityscan')
-        conf = CONST.__getattribute__('dir_functest_conf')
-        kwargs["cmd"] = ('. {0}/stackrc && '
-                         'cd {1} && '
-                         'python security_scan.py --config config.ini && '
-                         'cd -'.format(conf, repo))
-        super(SecurityScan, self).__init__(**kwargs)
diff --git a/functest/opnfv_tests/vnf/rnc/__init__.py b/functest/opnfv_tests/vnf/rnc/__init__.py
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/functest/opnfv_tests/vnf/rnc/parser.py b/functest/opnfv_tests/vnf/rnc/parser.py
deleted file mode 100644 (file)
index 3e6b138..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright 2016 ZTE Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-import functest.core.feature as base
-from functest.utils.constants import CONST
-
-
-class Parser(base.BashFeature):
-    def __init__(self, **kwargs):
-        repo = CONST.__getattribute__('dir_repo_parser')
-        kwargs["cmd"] = 'cd %s/tests && ./functest_run.sh' % repo
-        super(Parser, self).__init__(**kwargs)
index ac4b04c..bd7197f 100644 (file)
@@ -17,6 +17,8 @@ import mock
 from functest.core import feature
 from functest.core import testcase
 
+# logging must be disabled else it calls time.time()
+# what will break these unit tests.
 logging.disable(logging.CRITICAL)
 
 
@@ -27,10 +29,11 @@ class FeatureTestingBase(unittest.TestCase):
     _repo = "dir_repo_copper"
     _cmd = "cd /home/opnfv/repos/foo/tests && bash run.sh && cd -"
     _output_file = '/home/opnfv/functest/results/bar.log'
+    feature = None
 
     @mock.patch('time.time', side_effect=[1, 2])
     def _test_run(self, status, mock_method=None):
-        self.assertEqual(self.feature.run(), status)
+        self.assertEqual(self.feature.run(cmd=self._cmd), status)
         if status == testcase.TestCase.EX_OK:
             self.assertEqual(self.feature.criteria, 'PASS')
         else:
@@ -44,8 +47,15 @@ class FeatureTesting(FeatureTestingBase):
 
     def setUp(self):
         self.feature = feature.Feature(
-            project_name=self._project_name, case_name=self._case_name,
-            cmd=self._cmd)
+            project_name=self._project_name, case_name=self._case_name)
+
+    def test_run_exc(self):
+        # pylint: disable=bad-continuation
+        with mock.patch.object(
+                self.feature, 'execute',
+                side_effect=Exception) as mock_method:
+            self._test_run(testcase.TestCase.EX_RUN_ERROR)
+            mock_method.assert_called_once_with(cmd=self._cmd)
 
     def test_run(self):
         self._test_run(testcase.TestCase.EX_RUN_ERROR)
@@ -55,8 +65,12 @@ class BashFeatureTesting(FeatureTestingBase):
 
     def setUp(self):
         self.feature = feature.BashFeature(
-            project_name=self._project_name, case_name=self._case_name,
-            cmd=self._cmd)
+            project_name=self._project_name, case_name=self._case_name)
+
+    @mock.patch("functest.utils.functest_utils.execute_command")
+    def test_run_no_cmd(self, mock_method=None):
+        self.assertEqual(self.feature.run(), testcase.TestCase.EX_RUN_ERROR)
+        mock_method.assert_not_called()
 
     @mock.patch("functest.utils.functest_utils.execute_command",
                 return_value=1)
diff --git a/functest/tests/unit/features/test_copper.py b/functest/tests/unit/features/test_copper.py
deleted file mode 100644 (file)
index 56bf413..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import copper
-from functest.utils.constants import CONST
-
-
-class CopperTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "copper-notification"
-    _project_name = "copper"
-
-    def setUp(self):
-        self.copper = copper.Copper(case_name=self._case_name,
-                                    project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.copper.project_name, self._project_name)
-        repo = CONST.__getattribute__('dir_repo_copper')
-        self.assertEqual(
-            self.copper.cmd,
-            "cd {}/tests && bash run.sh && cd -".format(repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_doctor.py b/functest/tests/unit/features/test_doctor.py
deleted file mode 100644 (file)
index 650d150..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import doctor
-from functest.utils.constants import CONST
-
-
-class DoctorTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "doctor-notification"
-    _project_name = "doctor"
-
-    def setUp(self):
-        self.doctor = doctor.Doctor(case_name=self._case_name,
-                                    project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.doctor.project_name, self._project_name)
-        self.assertEqual(self.doctor.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_doctor')
-        self.assertEqual(
-            self.doctor.cmd,
-            'cd {}/tests && ./run.sh'.format(repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_domino.py b/functest/tests/unit/features/test_domino.py
deleted file mode 100644 (file)
index f311af3..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import domino
-from functest.utils.constants import CONST
-
-
-class DominoTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "domino-multinode"
-    _project_name = "domino"
-
-    def setUp(self):
-        self.domino = domino.Domino(case_name=self._case_name,
-                                    project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.domino.project_name, self._project_name)
-        self.assertEqual(self.domino.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_domino')
-        self.assertEqual(
-            self.domino.cmd,
-            'cd {} && ./tests/run_multinode.sh'.format(repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_netready.py b/functest/tests/unit/features/test_netready.py
deleted file mode 100644 (file)
index 9684019..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import netready
-from functest.utils.constants import CONST
-
-
-class NetreadyTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "gluon_vping"
-    _project_name = "netready"
-
-    def setUp(self):
-        self.netready = netready.GluonVping(case_name=self._case_name,
-                                            project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.netready.project_name, self._project_name)
-        self.assertEqual(self.netready.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_netready')
-        self.assertEqual(
-            self.netready.cmd,
-            'cd {}/test/functest && python ./gluon-test-suite.py'.format(repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_odl_sfc.py b/functest/tests/unit/features/test_odl_sfc.py
deleted file mode 100644 (file)
index 5673e2b..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import odl_sfc
-from functest.utils.constants import CONST
-
-
-class OpenDaylightSFCTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "functest-odl-sfc"
-    _project_name = "sfc"
-
-    def setUp(self):
-        self.odl_sfc = odl_sfc.OpenDaylightSFC(
-            case_name="functest-odl-sfc",
-            project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.odl_sfc.project_name, "sfc")
-        self.assertEqual(self.odl_sfc.case_name, "functest-odl-sfc")
-        repo = CONST.__getattribute__('dir_repo_sfc')
-        dir_sfc_functest = '{}/sfc/tests/functest'.format(repo)
-        self.assertEqual(
-            self.odl_sfc.cmd,
-            'cd {} && python ./run_tests.py'.format(dir_sfc_functest))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_promise.py b/functest/tests/unit/features/test_promise.py
deleted file mode 100644 (file)
index 8fa1fba..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import promise
-from functest.utils.constants import CONST
-
-
-class PromiseTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "promise"
-    _project_name = "promise"
-
-    def setUp(self):
-        self.promise = promise.Promise(case_name=self._case_name,
-                                       project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.promise.project_name, self._project_name)
-        self.assertEqual(self.promise.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_promise')
-        self.assertEqual(
-            self.promise.cmd,
-            'cd {}/promise/test/functest && python ./run_tests.py'.format(
-                repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_sdnvpn.py b/functest/tests/unit/features/test_sdnvpn.py
deleted file mode 100644 (file)
index 75657fc..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import sdnvpn
-from functest.utils.constants import CONST
-
-
-class SdnVpnTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "bgpvpn"
-    _project_name = "sdnvpn"
-
-    def setUp(self):
-        self.sdnvpn = sdnvpn.SdnVpnTests(case_name=self._case_name,
-                                         project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.sdnvpn.project_name, self._project_name)
-        self.assertEqual(self.sdnvpn.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_sdnvpn')
-        self.assertEqual(
-            self.sdnvpn.cmd,
-            'cd {}/sdnvpn/test/functest && python ./run_tests.py'.format(repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/features/test_security_scan.py b/functest/tests/unit/features/test_security_scan.py
deleted file mode 100644 (file)
index 61ae9dc..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.features import security_scan
-from functest.utils.constants import CONST
-
-
-class SecurityScanTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "security_scan"
-    _project_name = "security_scan"
-
-    def setUp(self):
-        self.sscan = security_scan.SecurityScan(
-            case_name=self._case_name, project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.sscan.project_name, self._project_name)
-        self.assertEqual(self.sscan.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_securityscan')
-        self.assertEqual(
-            self.sscan.cmd, (
-                '. {0}/stackrc && cd {1} && '
-                'python security_scan.py --config config.ini && '
-                'cd -'.format(
-                    CONST.__getattribute__("dir_functest_conf"),
-                    repo)))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
diff --git a/functest/tests/unit/vnf/rnc/test_parser.py b/functest/tests/unit/vnf/rnc/test_parser.py
deleted file mode 100644 (file)
index 9e310cc..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2017 Orange and others.
-#
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Apache License, Version 2.0
-# which accompanies this distribution, and is available at
-# http://www.apache.org/licenses/LICENSE-2.0
-
-# pylint: disable=missing-docstring
-
-import logging
-import unittest
-
-from functest.opnfv_tests.vnf.rnc import parser
-from functest.utils.constants import CONST
-
-
-class ParserTesting(unittest.TestCase):
-
-    logging.disable(logging.CRITICAL)
-
-    _case_name = "parser-basics"
-    _project_name = "parser"
-
-    def setUp(self):
-        self.parser = parser.Parser(
-            case_name=self._case_name, project_name=self._project_name)
-
-    def test_init(self):
-        self.assertEqual(self.parser.project_name, self._project_name)
-        self.assertEqual(self.parser.case_name, self._case_name)
-        repo = CONST.__getattribute__('dir_repo_parser')
-        self.assertEqual(
-            self.parser.cmd,
-            'cd {}/tests && ./functest_run.sh'.format(repo))
-
-
-if __name__ == "__main__":
-    unittest.main(verbosity=2)
index 5a66dd7..917c8ee 100755 (executable)
@@ -43,7 +43,6 @@ nosetests --with-xunit \
          --cover-package=functest.core \
          --cover-package=functest.opnfv_tests.sdn.odl.odl \
          --cover-package=functest.opnfv_tests.vnf.ims \
-         --cover-package=functest.opnfv_tests.vnf.rnc \
          --cover-package=functest.utils \
          --cover-package=functest.opnfv_tests.features \
          --cover-package=functest.opnfv_tests.openstack \