aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorelen-volodina <elen-volodina@yandex-team.com>2024-06-14 09:55:43 +0300
committerelen-volodina <elen-volodina@yandex-team.com>2024-06-14 10:09:54 +0300
commitb2eaf5ada02c298809548e14d7a63347e873ef29 (patch)
treef14e30eabec0d23d6ad7afc87f4c3809cc158011
parentf1f6b4c61e0245953416e53e3e2f1fd1c7103434 (diff)
downloadydb-b2eaf5ada02c298809548e14d7a63347e873ef29.tar.gz
pass module lang in tests
pass module_lang in tests bc7452000cd4082a121a66c56609fe475adc31f6
-rw-r--r--build/plugins/ytest.py30
1 files changed, 15 insertions, 15 deletions
diff --git a/build/plugins/ytest.py b/build/plugins/ytest.py
index 9ebea4379e..d631f21ac3 100644
--- a/build/plugins/ytest.py
+++ b/build/plugins/ytest.py
@@ -632,7 +632,7 @@ def ktlint(unit, *args):
# TODO remove FILES, see DEVTOOLS-7052
'FILES': serialized_test_files,
'TEST-FILES': serialized_test_files,
- 'MODULE_LANG': consts.ModuleLang.KOTLIN,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
test_record.update(extra_test_dart_data)
@@ -699,7 +699,7 @@ def java_style(unit, *args):
'TEST-FILES': serialized_test_files,
'JDK_LATEST_VERSION': unit.get('JDK_LATEST_VERSION'),
'JDK_RESOURCE': 'JDK' + (unit.get('JDK_VERSION') or unit.get('JDK_REAL_VERSION') or '_DEFAULT'),
- 'MODULE_LANG': consts.ModuleLang.JAVA,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -746,7 +746,7 @@ def gofmt(unit, *args):
# TODO remove FILES, see DEVTOOLS-7052
'FILES': serialized_test_files,
'TEST-FILES': serialized_test_files,
- 'MODULE_LANG': consts.ModuleLang.GO,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -788,7 +788,7 @@ def govet(unit, *args):
# TODO remove FILES, see DEVTOOLS-7052
'FILES': serialized_test_files,
'TEST-FILES': serialized_test_files,
- 'MODULE_LANG': consts.ModuleLang.GO,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -859,7 +859,7 @@ def onadd_check_py_imports(unit, *args):
# TODO remove FILES, see DEVTOOLS-7052
'FILES': test_files,
'TEST-FILES': test_files,
- 'MODULE_LANG': consts.ModuleLang.PY,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
if unit.get('NO_CHECK_IMPORTS_FOR_VALUE') != "None":
test_record["NO-CHECK"] = serialize_list(get_values_list(unit, 'NO_CHECK_IMPORTS_FOR_VALUE') or ["*"])
@@ -939,7 +939,7 @@ def onadd_pytest_bin(unit, *args):
'BUILD-FOLDER-PATH': _common.strip_roots(unit_path),
'BLOB': unit.get('TEST_BLOB_DATA'),
'CANONIZE_SUB_PATH': unit.get('CANONIZE_SUB_PATH'),
- 'MODULE_LANG': consts.ModuleLang.PY,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
if binary_path:
test_record['BINARY-PATH'] = _common.strip_roots(binary_path)
@@ -1053,7 +1053,7 @@ def onjava_test(unit, *args):
'JDK_RESOURCE': 'JDK' + (unit.get('JDK_VERSION') or unit.get('JDK_REAL_VERSION') or '_DEFAULT'),
'JDK_FOR_TESTS': 'JDK' + (unit.get('JDK_VERSION') or unit.get('JDK_REAL_VERSION') or '_DEFAULT') + '_FOR_TESTS',
'YT-SPEC': serialize_list(yt_spec_values),
- 'MODULE_LANG': consts.ModuleLang.JAVA,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
test_classpath_origins = unit.get('TEST_CLASSPATH_VALUE')
if test_classpath_origins:
@@ -1095,7 +1095,7 @@ def onjava_test_deps(unit, *args):
'IGNORE_CLASSPATH_CLASH': ' '.join(get_values_list(unit, 'JAVA_IGNORE_CLASSPATH_CLASH_VALUE')),
# JTEST/JTEST_FOR only
'MODULE_TYPE': unit.get('MODULE_TYPE'),
- 'MODULE_LANG': consts.ModuleLang.JAVA,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
if mode == 'strict':
test_record['STRICT_CLASSPATH_CLASH'] = 'yes'
@@ -1472,7 +1472,7 @@ def clang_tidy(unit, *args, from_other_type=False):
'TEST_IOS_RUNTIME_TYPE': unit.get('TEST_IOS_RUNTIME_TYPE_VALUE'),
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
- 'MODULE_LANG': consts.ModuleLang.CPP,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -1545,7 +1545,7 @@ def unittest_py(unit, *args):
'TEST_IOS_RUNTIME_TYPE': unit.get('TEST_IOS_RUNTIME_TYPE_VALUE'),
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
- 'MODULE_LANG': consts.ModuleLang.CPP,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -1618,7 +1618,7 @@ def gunittest(unit, *args):
'TEST_IOS_RUNTIME_TYPE': unit.get('TEST_IOS_RUNTIME_TYPE_VALUE'),
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
- 'MODULE_LANG': consts.ModuleLang.CPP,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -1691,7 +1691,7 @@ def g_benchmark(unit, *args):
'TEST_IOS_RUNTIME_TYPE': unit.get('TEST_IOS_RUNTIME_TYPE_VALUE'),
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
- 'MODULE_LANG': consts.ModuleLang.CPP,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
benchmark_opts = get_unit_list_variable(unit, 'BENCHMARK_OPTS_VALUE')
@@ -1772,7 +1772,7 @@ def go_test(unit, *args):
'TEST_IOS_RUNTIME_TYPE': unit.get('TEST_IOS_RUNTIME_TYPE_VALUE'),
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
- 'MODULE_LANG': consts.ModuleLang.GO,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
data = dump_test(unit, test_record)
@@ -2005,7 +2005,7 @@ def y_benchmark(unit, *args):
'TEST_IOS_RUNTIME_TYPE': unit.get('TEST_IOS_RUNTIME_TYPE_VALUE'),
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
- 'MODULE_LANG': consts.ModuleLang.CPP,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
benchmark_opts = get_unit_list_variable(unit, 'BENCHMARK_OPTS_VALUE')
@@ -2152,7 +2152,7 @@ def go_bench(unit, *args):
'ANDROID_APK_TEST_ACTIVITY': unit.get('ANDROID_APK_TEST_ACTIVITY_VALUE'),
'TEST_PARTITION': unit.get("TEST_PARTITION"),
'GO_BENCH_TIMEOUT': unit.get('GO_BENCH_TIMEOUT'),
- 'MODULE_LANG': consts.ModuleLang.GO,
+ 'MODULE_LANG': unit.get("MODULE_LANG").lower() or consts.ModuleLang.UNKNOWN,
}
if "ya:run_go_benchmark" not in test_record["TAG"]: