Skip to content

Commit

Permalink
Patches gtest to not override a manually set GTEST_HAS_DEATH_TEST com…
Browse files Browse the repository at this point in the history
…piler define.

This compiler define can be manually set by the user
to disable gtest's death tests on unsupported platforms.
  • Loading branch information
kennyweiss committed Jul 7, 2017
1 parent e226270 commit d4c57e0
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -783,15 +783,17 @@ using ::std::tuple_size;
#endif // GTEST_HAS_STREAM_REDIRECTION

// Determines whether to support death tests.
#ifndef GTEST_HAS_DEATH_TEST
// Google Test does not support death tests for VC 7.1 and earlier as
// abort() in a VC 7.1 application compiled as GUI in debug config
// pops up a dialog window that cannot be suppressed programmatically.
#if (GTEST_OS_LINUX || GTEST_OS_CYGWIN || GTEST_OS_SOLARIS || \
# if (GTEST_OS_LINUX || GTEST_OS_CYGWIN || GTEST_OS_SOLARIS || \
(GTEST_OS_MAC && !GTEST_OS_IOS) || \
(GTEST_OS_WINDOWS_DESKTOP && _MSC_VER >= 1400) || \
GTEST_OS_WINDOWS_MINGW || GTEST_OS_AIX || GTEST_OS_HPUX || \
GTEST_OS_OPENBSD || GTEST_OS_QNX || GTEST_OS_FREEBSD)
# define GTEST_HAS_DEATH_TEST 1
# define GTEST_HAS_DEATH_TEST 1
# endif
#endif

// We don't support MSVC 7.1 with exceptions disabled now. Therefore
Expand Down

0 comments on commit d4c57e0

Please sign in to comment.