test: Add _win32_seterrormode.fail.cpp to silence Exception diaalogs on Windows desktop.
This commit is contained in:
15
test/_win32_seterrormode.fail.cpp
Normal file
15
test/_win32_seterrormode.fail.cpp
Normal file
@@ -0,0 +1,15 @@
|
||||
#include <windows.h>
|
||||
|
||||
namespace {
|
||||
|
||||
class Win32ctor {
|
||||
public:
|
||||
Win32ctor() {
|
||||
SetErrorMode(SEM_FAILCRITICALERRORS |
|
||||
SEM_NOGPFAULTERRORBOX |
|
||||
SEM_NOOPENFILEERRORBOX);
|
||||
}
|
||||
};
|
||||
|
||||
static Win32ctor ctor;
|
||||
}
|
@@ -68,7 +68,7 @@ class LibcxxTestFormat(lit.formats.FileBasedTest):
|
||||
exec_file.close()
|
||||
|
||||
try:
|
||||
compile_cmd = [self.cxx_under_test, '-o', exec_path,
|
||||
compile_cmd = [self.cxx_under_test, 'e:/llvm/libcxx/test/_win32_seterrormode.fail.cpp', '-o', exec_path,
|
||||
source_path] + self.cpp_flags + self.ld_flags
|
||||
cmd = compile_cmd
|
||||
out, err, exitCode = self.execute_command(cmd)
|
||||
|
Reference in New Issue
Block a user