Skip to content

Commit

Permalink
Merge b324fcb into b1e3f38
Browse files Browse the repository at this point in the history
  • Loading branch information
srz-zumix committed Aug 7, 2019
2 parents b1e3f38 + b324fcb commit 53362aa
Showing 1 changed file with 28 additions and 1 deletion.
29 changes: 28 additions & 1 deletion test/scoped_trace_tests.cpp
Expand Up @@ -6,7 +6,7 @@
*
* @author t.shirayanagi
* @par copyright
* Copyright (C) 2013-2016, Takazumi Shirayanagi\n
* Copyright (C) 2013-2019, Takazumi Shirayanagi\n
* This software is released under the new BSD License,
* see LICENSE
*/
Expand Down Expand Up @@ -68,6 +68,33 @@ IUTEST(ScopedTraceTest, Test)
#endif
}

#if IUTEST_HAS_EXCEPTIONS

class ScopedTraceExceptionTest : public ::iutest::Test
{
public:
#if !defined(IUTEST_USE_GTEST)
TestLogger logger;

void SetUp()
{
::iutest::detail::iuConsole::SetLogger(&logger);
}
void TearDown()
{
::iutest::detail::iuConsole::SetLogger(NULL);
}
#endif
}

IUTEST_F(ScopedTraceExceptionTest, Exception)
{
IUTEST_SCOPED_TRACE("Test Scope Exception");
throw "error";
}

#endif

#ifdef UNICODE
int wmain(int argc, wchar_t* argv[])
#else
Expand Down

0 comments on commit 53362aa

Please sign in to comment.