mirror of https://github.com/mongodb/mongo
Revert "SERVER-111758 Remove duplicates when --test_tag_filters=mongo_unittest is set (#42022)" (#42111)
Co-authored-by: auto-revert-processor <devprod-si-team@mongodb.com> GitOrigin-RevId: 4ee152e8494b9f4347cf87c663d98bbf62ac396f
This commit is contained in:
parent
d0024cffcc
commit
1d9473a008
|
|
@ -309,7 +309,7 @@
|
||||||
"id": "runTargets",
|
"id": "runTargets",
|
||||||
"command": "shellCommand.execute",
|
"command": "shellCommand.execute",
|
||||||
"args": {
|
"args": {
|
||||||
"command": "bazel query 'attr(tags, \"mongo_binary\", //...)' union 'attr(tags, \"mongo_unittest_target\", //...)' | grep mongo | grep -v \"_with_debug\" | grep -v third_party | sed 's;//;bazel-bin/;g' | sed 's;:;/;g'",
|
"command": "bazel query 'attr(tags, \"mongo_binary\", //...)' union 'attr(tags, \"mongo_unittest\", //...)' | grep mongo | grep -v \"_with_debug\" | grep -v third_party | sed 's;//;bazel-bin/;g' | sed 's;:;/;g'",
|
||||||
"cwd": "${workspaceFolder}",
|
"cwd": "${workspaceFolder}",
|
||||||
"taskId": "runTargets",
|
"taskId": "runTargets",
|
||||||
"rememberPrevious": true,
|
"rememberPrevious": true,
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,7 @@ TEST_TAGS = {
|
||||||
"mongo_benchmark": 1,
|
"mongo_benchmark": 1,
|
||||||
"mongo_fuzzer_test": 1,
|
"mongo_fuzzer_test": 1,
|
||||||
"mongo_integration_test": 1,
|
"mongo_integration_test": 1,
|
||||||
"mongo_unittest_target": 1,
|
"mongo_unittest": 1,
|
||||||
"mongo_unittest_first_group": 1,
|
"mongo_unittest_first_group": 1,
|
||||||
"mongo_unittest_second_group": 1,
|
"mongo_unittest_second_group": 1,
|
||||||
"mongo_unittest_third_group": 1,
|
"mongo_unittest_third_group": 1,
|
||||||
|
|
|
||||||
|
|
@ -831,7 +831,7 @@ def _mongo_cc_binary_and_test(
|
||||||
name = name,
|
name = name,
|
||||||
binary_with_debug = ":" + name + WITH_DEBUG_SUFFIX,
|
binary_with_debug = ":" + name + WITH_DEBUG_SUFFIX,
|
||||||
type = "program",
|
type = "program",
|
||||||
tags = original_tags + ["final_binary"],
|
tags = original_tags + ["final_target"],
|
||||||
enabled = SEPARATE_DEBUG_ENABLED,
|
enabled = SEPARATE_DEBUG_ENABLED,
|
||||||
enable_pdb = PDB_GENERATION_ENABLED,
|
enable_pdb = PDB_GENERATION_ENABLED,
|
||||||
deps = all_deps,
|
deps = all_deps,
|
||||||
|
|
@ -839,15 +839,12 @@ def _mongo_cc_binary_and_test(
|
||||||
exec_properties = exec_properties,
|
exec_properties = exec_properties,
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
final_binary_tags = original_tags + ["final_binary"]
|
|
||||||
if "mongo_unittest_target" in final_binary_tags:
|
|
||||||
final_binary_tags += ["mongo_unittest"]
|
|
||||||
native.cc_test(**args)
|
native.cc_test(**args)
|
||||||
extract_debuginfo_test(
|
extract_debuginfo_test(
|
||||||
name = name,
|
name = name,
|
||||||
binary_with_debug = ":" + name + WITH_DEBUG_SUFFIX,
|
binary_with_debug = ":" + name + WITH_DEBUG_SUFFIX,
|
||||||
type = "program",
|
type = "program",
|
||||||
tags = final_binary_tags,
|
tags = original_tags + ["final_target"],
|
||||||
enabled = SEPARATE_DEBUG_ENABLED,
|
enabled = SEPARATE_DEBUG_ENABLED,
|
||||||
enable_pdb = PDB_GENERATION_ENABLED,
|
enable_pdb = PDB_GENERATION_ENABLED,
|
||||||
deps = all_deps,
|
deps = all_deps,
|
||||||
|
|
@ -856,7 +853,7 @@ def _mongo_cc_binary_and_test(
|
||||||
)
|
)
|
||||||
|
|
||||||
native.sh_test(
|
native.sh_test(
|
||||||
name = name + "_remote_exec_wrapper",
|
name = name + "_remote_exec",
|
||||||
srcs = [
|
srcs = [
|
||||||
"//bazel:test_wrapper",
|
"//bazel:test_wrapper",
|
||||||
],
|
],
|
||||||
|
|
@ -1075,7 +1072,7 @@ def mongo_cc_unit_test(
|
||||||
header_deps = header_deps,
|
header_deps = header_deps,
|
||||||
visibility = visibility,
|
visibility = visibility,
|
||||||
data = data,
|
data = data,
|
||||||
tags = tags + ["mongo_unittest_target"],
|
tags = tags + ["mongo_unittest"],
|
||||||
copts = copts,
|
copts = copts,
|
||||||
linkopts = linkopts,
|
linkopts = linkopts,
|
||||||
includes = includes,
|
includes = includes,
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ bazel_tags_to_autogenerate = [
|
||||||
"mongo_benchmark",
|
"mongo_benchmark",
|
||||||
"mongo_fuzzer_test",
|
"mongo_fuzzer_test",
|
||||||
"mongo_integration_test",
|
"mongo_integration_test",
|
||||||
"mongo_unittest_target",
|
"mongo_unittest",
|
||||||
"mongo_unittest_first_group",
|
"mongo_unittest_first_group",
|
||||||
"mongo_unittest_second_group",
|
"mongo_unittest_second_group",
|
||||||
"mongo_unittest_third_group",
|
"mongo_unittest_third_group",
|
||||||
|
|
|
||||||
|
|
@ -239,7 +239,7 @@ def validate_bazel_groups(generate_report, fix):
|
||||||
[
|
[
|
||||||
bazel_bin,
|
bazel_bin,
|
||||||
"query",
|
"query",
|
||||||
'kind(extract_debug, attr(tags, "[\[ ]mongo_unittest_target[,\]]", //src/...))',
|
'kind(extract_debug, attr(tags, "[\[ ]mongo_unittest[,\]]", //src/...))',
|
||||||
]
|
]
|
||||||
+ query_opts,
|
+ query_opts,
|
||||||
capture_output=True,
|
capture_output=True,
|
||||||
|
|
|
||||||
|
|
@ -41,7 +41,7 @@ def main(testlog_dir: str):
|
||||||
testcase = testsuite.find("testcase")
|
testcase = testsuite.find("testcase")
|
||||||
|
|
||||||
# Replace part of the name added by the remote test wrapper script
|
# Replace part of the name added by the remote test wrapper script
|
||||||
test_file = testcase.attrib["name"].replace("_remote_exec_wrapper", "")
|
test_file = testcase.attrib["name"].replace("_remote_exec", "")
|
||||||
|
|
||||||
if testcase.find("error") is not None:
|
if testcase.find("error") is not None:
|
||||||
status = "fail"
|
status = "fail"
|
||||||
|
|
|
||||||
|
|
@ -59,9 +59,9 @@ def _copy_bins_to_upload(failed_tests: List[str], upload_bin_dir: str, upload_li
|
||||||
# Search both in the top level remote exec shellscript wrapper output directory, and in the
|
# Search both in the top level remote exec shellscript wrapper output directory, and in the
|
||||||
# binary output directory.
|
# binary output directory.
|
||||||
failed_tests += [
|
failed_tests += [
|
||||||
failed_test.replace("_remote_exec_wrapper", "")
|
failed_test.replace("_remote_exec", "")
|
||||||
for failed_test in failed_tests
|
for failed_test in failed_tests
|
||||||
if "_remote_exec_wrapper" in failed_test
|
if "_remote_exec" in failed_test
|
||||||
]
|
]
|
||||||
for failed_test in failed_tests:
|
for failed_test in failed_tests:
|
||||||
full_binary_path = bazel_bin_dir / failed_test
|
full_binary_path = bazel_bin_dir / failed_test
|
||||||
|
|
|
||||||
|
|
@ -434,7 +434,7 @@ tasks:
|
||||||
# compiled. We therefore link them without debug symbols to compile them faster.
|
# compiled. We therefore link them without debug symbols to compile them faster.
|
||||||
bazel_args: >-
|
bazel_args: >-
|
||||||
--config=evg
|
--config=evg
|
||||||
--build_tag_filters=-mongo_unittest_target,mongo_binary,mongo_benchmark,mongo_integration_test
|
--build_tag_filters=-mongo_unittest,mongo_binary,mongo_benchmark,mongo_integration_test
|
||||||
--linkopt=-s
|
--linkopt=-s
|
||||||
task_compile_flags: ${compile_all_but_not_unittests_flags|--linkopt=-s}
|
task_compile_flags: ${compile_all_but_not_unittests_flags|--linkopt=-s}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -800,7 +800,7 @@ tasks:
|
||||||
target: >-
|
target: >-
|
||||||
//src/mongo/...
|
//src/mongo/...
|
||||||
args: >-
|
args: >-
|
||||||
--test_tag_filters=mongo_unittest_target_debug,-final_binary,-code_coverage_quarantine_debug
|
--test_tag_filters=mongo_unittest_debug,-final_target,-code_coverage_quarantine_debug
|
||||||
--test_timeout=600
|
--test_timeout=600
|
||||||
--verbose_failures
|
--verbose_failures
|
||||||
--instrumentation_filter="^//src/mongo[/:],-^//src/mongo/util:boost_assert_shim,-^//src/mongo/util:icu,-^//src/mongo/db/modules/enterprise/src/streams[/:]"
|
--instrumentation_filter="^//src/mongo[/:],-^//src/mongo/util:boost_assert_shim,-^//src/mongo/util:icu,-^//src/mongo/db/modules/enterprise/src/streams[/:]"
|
||||||
|
|
@ -1043,8 +1043,8 @@ tasks:
|
||||||
bazel_args: >-
|
bazel_args: >-
|
||||||
--config=evg
|
--config=evg
|
||||||
--linkstatic=False
|
--linkstatic=False
|
||||||
--test_tag_filters=mongo_unittest_target,-final_binary,-intermediate_debug,-incompatible_with_bazel_remote_test
|
--test_tag_filters=mongo_unittest,-final_target,-intermediate_debug,-incompatible_with_bazel_remote_test
|
||||||
--build_tag_filters=mongo_unittest_target,-incompatible_with_bazel_remote_test
|
--build_tag_filters=mongo_unittest,-incompatible_with_bazel_remote_test
|
||||||
|
|
||||||
- name: unit_tests_remote_exec_incompatible
|
- name: unit_tests_remote_exec_incompatible
|
||||||
tags: ["assigned_to_jira_team_devprod_correctness", "auxiliary"]
|
tags: ["assigned_to_jira_team_devprod_correctness", "auxiliary"]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue