Details
-
Bug
-
Resolution: Fixed
-
Major - P3
-
None
-
None
-
Fully Compatible
-
ALL
-
TIG 2017-10-23
Description
Here's a sample yaml file describing a custom dbtest suite:
|
my_dbtests.yml |
test_kind: db_test
|
|
|
selector:
|
include_suites:
|
- DocumentSourceCursorTest
|
- PlanExecutor*
|
- Query*
|
- query*
|
- executor_registry
|
- CursorManager*
|
|
|
executor:
|
config:
|
dbtest_options:
|
dur: ''
|
before SERVER-30980, this suite ran a fair number of suites, after that commit I instead get:
python buildscripts/resmoke.py --suites=my_dbtests
|
[resmoke] 2017-09-28T16:15:23.363-0400 resmoke.py invocation: buildscripts/resmoke.py --suites=my_dbtests
|
[resmoke] 2017-09-28T16:15:23.495-0400 YAML configuration of suite my_dbtests
|
test_kind: db_test
|
|
|
selector:
|
include_suites:
|
- DocumentSourceCursorTest
|
- PlanExecutor*
|
- Query*
|
- query*
|
- executor_registry
|
- CursorManager*
|
|
|
executor:
|
config:
|
dbtest_options:
|
dur: ''
|
|
|
logging:
|
executor:
|
format: '[%(name)s] %(asctime)s %(message)s'
|
handlers:
|
- class: logging.StreamHandler
|
fixture:
|
format: '[%(name)s] %(message)s'
|
handlers:
|
- class: logging.StreamHandler
|
tests:
|
format: '[%(name)s] %(asctime)s %(message)s'
|
handlers:
|
- class: logging.StreamHandler
|
[executor] 2017-09-28T16:15:23.496-0400 Skipping db_tests, no tests to run
|
[resmoke] 2017-09-28T16:15:23.496-0400 ================================================================================
|
[resmoke] 2017-09-28T16:15:23.496-0400 Summary of my_dbtests suite: No tests ran.
|
Suite did not run any tests.
|
This patch fixed it for me locally:
diff --git a/buildscripts/resmokelib/selector.py b/buildscripts/resmokelib/selector.py
|
index 057c54f..f97b17b 100644
|
--- a/buildscripts/resmokelib/selector.py
|
+++ b/buildscripts/resmokelib/selector.py
|
@@ -487,10 +487,14 @@ class _DbTestSelector(_Selector):
|
return dbtests
|
|
test_files = _TestList(self._test_file_explorer, dbtests)
|
- for suite_pattern in selector_config.include_suites:
|
- test_files.match_pattern(suite_pattern)
|
-
|
- return test_files.get_tests()
|
+ filtered_tests = []
|
+ for test in test_files.get_tests():
|
+ for suite_pattern in selector_config.include_suites:
|
+ if test == suite_pattern or fnmatch.fnmatchcase(test, suite_pattern):
|
+ filtered_tests.append(test)
|
+ break
|
+
|
+ return filtered_tests |
Attachments
Issue Links
- is related to
-
SERVER-30980 Add support for more complex tag matching in resmoke.py
-
- Closed
-