From 226da7d364041e534c017ee4606088d5951ddab1 Mon Sep 17 00:00:00 2001 From: Calen Pennington <cale@edx.org> Date: Tue, 10 May 2016 15:05:46 -0400 Subject: [PATCH] Make LMS tests run concurrently --- pavelib/utils/test/suites/nose_suite.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/pavelib/utils/test/suites/nose_suite.py b/pavelib/utils/test/suites/nose_suite.py index 8f5007e3837..f5557f6fc53 100644 --- a/pavelib/utils/test/suites/nose_suite.py +++ b/pavelib/utils/test/suites/nose_suite.py @@ -120,12 +120,13 @@ class SystemTestSuite(NoseTestSuite): def cmd(self): cmd = ( './manage.py {system} test --verbosity={verbosity} ' - '{test_id} {test_opts} --settings=test {extra} ' + '{test_id} {test_opts} --settings=test {system_opts} {extra} ' '--with-xunitmp --xunitmp-file={xunit_report}'.format( system=self.root, verbosity=self.verbosity, test_id=self.test_id, test_opts=self.test_options_flags, + system_opts=self._system_options, extra=self.extra_args, xunit_report=self.report_dir / "nosetests.xml", ) @@ -133,6 +134,16 @@ class SystemTestSuite(NoseTestSuite): return self._under_coverage_cmd(cmd) + @property + def _system_options(self): + """ + Test arguments that are only enabled for specific systems. + """ + if self.root == 'lms': + return '--with-randomly --with-database-isolation --processes=-1' + + return '' + @property def _default_test_id(self): """ -- GitLab