Reland "[gn build] (manually) port 6fe2beba7d (ExceptionTests)"

This reverts commit 98d0f8f2ff.
6fe2beba7d relanded in 1dba6b37bd.
This commit is contained in:
Nico Weber 2021-10-08 07:17:04 -04:00
parent ff013b6100
commit 842035d8bd
3 changed files with 28 additions and 4 deletions

View File

@ -29,13 +29,16 @@ group("unittests") {
]
}
if (host_os != "win") {
# FIXME: libclang unit tests are disabled on Windows due
# to failures, mostly in libclang.VirtualFileOverlay_*.
# FIXME: Also, the executable can't find libclang.dll since that's
# in a different directory.
deps += [
# FIXME: libclang unit tests are disabled on Windows due
# to failures, mostly in libclang.VirtualFileOverlay_*.
# FIXME: Also, the executable can't find libclang.dll since that's
# in a different directory.
"libclang:libclangTests",
"libclang/CrashTests:libclangCrashTests",
# Exceptions on Windows are not yet supported.
"Interpreter/ExceptionTests:ClangReplInterpreterExceptionTests",
]
}
testonly = true

View File

@ -0,0 +1,20 @@
import("//llvm/utils/unittest/unittest.gni")
unittest("ClangReplInterpreterExceptionTests") {
configs += [ "//llvm/utils/gn/build:clang_code" ]
configs -= [
"//llvm/utils/gn/build:no_exceptions",
"//llvm/utils/gn/build:no_rtti",
]
deps = [
"//clang/lib/AST",
"//clang/lib/Basic",
"//clang/lib/Interpreter",
"//clang/lib/Frontend",
"//llvm/lib/IR",
"//llvm/lib/ExecutionEngine/Orc",
"//llvm/lib/Support",
"//llvm/lib/Target:TargetsToBuild",
]
sources = [ "InterpreterExceptionTest.cpp" ]
}

View File

@ -27,6 +27,7 @@ static_library("gtest") {
]
public_configs = [ ":googletest_config" ]
configs -= [ "//llvm/utils/gn/build:warn_covered_switch_default" ]
configs -= [ "//llvm/utils/gn/build:no_rtti" ]
sources = [
"googlemock/src/gmock-all.cc",
"googletest/src/gtest-all.cc",