summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/core/tests/test_loader.py
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2018-07-12 11:10:38 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-07-18 10:18:41 +0100
commit4e4958cba2e083eac20e2770e04bfc7d56d9db42 (patch)
treeb8fb57f9b3a3e37b3a5f095c70c127af9bce82fa /meta/lib/oeqa/core/tests/test_loader.py
parentebd97e728ae1bd9442299c871a07a1b3b9f9efdf (diff)
downloadpoky-4e4958cba2e083eac20e2770e04bfc7d56d9db42.tar.gz
oeqa/core/threaded: Remove in favour of using concurrenttests
We have several options for parallel processing in oeqa, parallel execution of modules, threading and mulitple processes for the runners. After much experimentation is appears the most scalable and least invasive approach is multiple processes using concurrenttestsuite from testtools. This means we can drop the current threading code which is only used by the sdk test execution. oeqa/decorator/depends: Remove threading code Revert "oeqa/sdk: Enable usage of OEQA thread mode" This reverts commit adc434c0636b7dea2ef70c8d2c8e61cdb5c703b1. Revert "oeqa/core/tests: Add tests of OEQA Threaded mode" This reverts commit a4eef558c9933eb32413b61ff80a11b999951b40. Revert "oeqa/core/decorator/oetimeout: Add support for OEQA threaded mode" This reverts commit d3d4ba902dee8b19fa1054330cffdf73f9b81fe7. (From OE-Core rev: a98ab5e560e73b6988512fbae5cefe9e42ceed53) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/core/tests/test_loader.py')
-rwxr-xr-xmeta/lib/oeqa/core/tests/test_loader.py30
1 files changed, 1 insertions, 29 deletions
diff --git a/meta/lib/oeqa/core/tests/test_loader.py b/meta/lib/oeqa/core/tests/test_loader.py
index e0d917d317..b79b8bad4d 100755
--- a/meta/lib/oeqa/core/tests/test_loader.py
+++ b/meta/lib/oeqa/core/tests/test_loader.py
@@ -1,6 +1,6 @@
1#!/usr/bin/env python3 1#!/usr/bin/env python3
2 2
3# Copyright (C) 2016-2017 Intel Corporation 3# Copyright (C) 2016 Intel Corporation
4# Released under the MIT license (see COPYING.MIT) 4# Released under the MIT license (see COPYING.MIT)
5 5
6import os 6import os
@@ -82,33 +82,5 @@ class TestLoader(TestBase):
82 msg = 'Expected modules from two different paths' 82 msg = 'Expected modules from two different paths'
83 self.assertEqual(modules, expected_modules, msg=msg) 83 self.assertEqual(modules, expected_modules, msg=msg)
84 84
85 def test_loader_threaded(self):
86 cases_path = self.cases_path
87
88 self.cases_path = [os.path.join(self.cases_path, 'loader', 'threaded')]
89
90 tc = self._testLoaderThreaded()
91 self.assertEqual(len(tc.suites), 3, "Expected to be 3 suites")
92
93 case_ids = ['threaded.ThreadedTest.test_threaded_no_depends',
94 'threaded.ThreadedTest2.test_threaded_same_module',
95 'threaded_depends.ThreadedTest3.test_threaded_depends']
96 for case in tc.suites[0]._tests:
97 self.assertEqual(case.id(),
98 case_ids[tc.suites[0]._tests.index(case)])
99
100 case_ids = ['threaded_alone.ThreadedTestAlone.test_threaded_alone']
101 for case in tc.suites[1]._tests:
102 self.assertEqual(case.id(),
103 case_ids[tc.suites[1]._tests.index(case)])
104
105 case_ids = ['threaded_module.ThreadedTestModule.test_threaded_module',
106 'threaded_module.ThreadedTestModule2.test_threaded_module2']
107 for case in tc.suites[2]._tests:
108 self.assertEqual(case.id(),
109 case_ids[tc.suites[2]._tests.index(case)])
110
111 self.cases_path = cases_path
112
113if __name__ == '__main__': 85if __name__ == '__main__':
114 unittest.main() 86 unittest.main()