You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
111 lines
2.9 KiB
111 lines
2.9 KiB
tests_dependencies = [
|
|
'//infer/lib/java/android:android',
|
|
'//dependencies/java/guava:guava',
|
|
'//dependencies/java/junit:hamcrest',
|
|
'//dependencies/java/jackson:jackson',
|
|
'//dependencies/java/jsr-305:jsr-305',
|
|
'//dependencies/java/junit:junit',
|
|
'//dependencies/java/opencsv:opencsv',
|
|
'//infer/tests/utils:utils'
|
|
]
|
|
|
|
integration_tests = [
|
|
'//infer/tests:integration_tests',
|
|
'//infer/tests:objc_tests',
|
|
'//infer/tests:c_tests',
|
|
'//infer/tests:cpp_tests',
|
|
'//infer/tests:objcpp_tests',
|
|
]
|
|
|
|
# ############### objc frontend tests ########################
|
|
|
|
objc_test_sources = glob(['objc/**/*.java'])
|
|
objc_frontend_test_deps = []
|
|
for test_source in objc_test_sources:
|
|
target_name = test_source.replace("/", "_")[:-len(".java")]
|
|
objc_frontend_test_deps.append(target_name)
|
|
|
|
java_test(
|
|
name=target_name,
|
|
srcs=[test_source],
|
|
deps=tests_dependencies,
|
|
visibility=integration_tests,
|
|
source='7',
|
|
target='7',
|
|
)
|
|
|
|
java_test(
|
|
name='objc_frontend_tests',
|
|
deps=[':' + x for x in objc_frontend_test_deps],
|
|
visibility=integration_tests,
|
|
)
|
|
|
|
# ############### c frontend tests ########################
|
|
|
|
c_test_sources = glob(['c/**/*.java'])
|
|
c_frontend_test_deps = []
|
|
for test_source in c_test_sources:
|
|
target_name = test_source.replace("/", "_")[:-len(".java")]
|
|
c_frontend_test_deps.append(target_name)
|
|
|
|
java_test(
|
|
name=target_name,
|
|
srcs=[test_source],
|
|
deps=tests_dependencies,
|
|
visibility=integration_tests,
|
|
source='7',
|
|
target='7',
|
|
)
|
|
|
|
java_test(
|
|
name='c_frontend_tests',
|
|
deps=[':' + x for x in c_frontend_test_deps],
|
|
visibility=integration_tests,
|
|
)
|
|
|
|
# ############### cpp frontend tests ########################
|
|
|
|
cpp_test_sources = glob(['cpp/**/*.java'])
|
|
cpp_frontend_test_deps = []
|
|
for test_source in cpp_test_sources:
|
|
target_name = test_source.replace("/", "_")[:-len(".java")]
|
|
cpp_frontend_test_deps.append(target_name)
|
|
|
|
java_test(
|
|
name=target_name,
|
|
srcs=[test_source],
|
|
deps=tests_dependencies,
|
|
visibility=integration_tests,
|
|
source='7',
|
|
target='7',
|
|
)
|
|
|
|
java_test(
|
|
name='cpp_frontend_tests',
|
|
deps=[':' + x for x in cpp_frontend_test_deps],
|
|
visibility=integration_tests,
|
|
)
|
|
|
|
# ############### objcpp frontend tests ########################
|
|
|
|
objcpp_test_sources = glob(['objcpp/**/*.java'])
|
|
objcpp_frontend_test_deps = []
|
|
for test_source in objcpp_test_sources:
|
|
target_name = test_source.replace("/", "_")[:-len(".java")]
|
|
objcpp_frontend_test_deps.append(target_name)
|
|
|
|
java_test(
|
|
name=target_name,
|
|
srcs=[test_source],
|
|
deps=tests_dependencies,
|
|
visibility=integration_tests,
|
|
source='7',
|
|
target='7',
|
|
)
|
|
|
|
java_test(
|
|
name='objcpp_frontend_tests',
|
|
deps=[':' + x for x in objcpp_frontend_test_deps],
|
|
visibility=integration_tests,
|
|
)
|