Skip to content

Commit

Permalink
toWstring() -> details::to_wstring()
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Smith committed Sep 12, 2023
1 parent 035bfb3 commit 80aec3a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion UnitTest/CppUnitTestAssert.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,5 +37,5 @@ void test::Assert::FailOnCondition(bool condition, const unsigned short* message
std::wstring GetAssertMessage(bool equality, const std::wstring& expected, const std::wstring& actual, const wchar_t *message); // declare caller
std::wstring test::Assert::GetAssertMessage(bool equality, const std::string& expected, const std::string& actual, const wchar_t *message)
{
return ::GetAssertMessage(equality, str::toWString(expected), str::toWString(actual), message); // and call!
return ::GetAssertMessage(equality, str::details::to_wstring(expected), str::details::to_wstring(actual), message); // and call!
}
2 changes: 1 addition & 1 deletion UnitTest/TestCase.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ inline void assert_almost_eq(const std::string& testName, long double X1, long d
#define TEST_ASSERT_EQ_MSG(msg, X1, X2) testName, Microsoft::VisualStudio::CppUnitTestFramework::Logger::WriteMessage(msg.c_str()); TEST_ASSERT_EQ(X1, X2)

#undef TEST_FAIL
#define TEST_FAIL(msg) { (void)testName; const auto vw(str::toWString(msg)); Microsoft::VisualStudio::CppUnitTestFramework::Assert::Fail(vw.c_str()); }
#define TEST_FAIL(msg) { (void)testName; const auto vw(str::details::to_wstring(msg)); Microsoft::VisualStudio::CppUnitTestFramework::Assert::Fail(vw.c_str()); }

#undef TEST_EXCEPTION
#undef TEST_THROWS
Expand Down

0 comments on commit 80aec3a

Please sign in to comment.