Fix util-test on Windows, take 2

This commit is contained in:
Victor Zverovich 2014-09-29 09:59:49 -07:00
parent 55a16eaec7
commit 810f42c0c7

View File

@ -638,7 +638,7 @@ TEST(UtilTest, UTF8ToUTF16) {
template <typename Converter> template <typename Converter>
void check_utf_conversion_error(const char *message) { void check_utf_conversion_error(const char *message) {
fmt::Writer out; fmt::MemoryWriter out;
fmt::internal::format_windows_error(out, ERROR_INVALID_PARAMETER, message); fmt::internal::format_windows_error(out, ERROR_INVALID_PARAMETER, message);
fmt::SystemError error(0, ""); fmt::SystemError error(0, "");
try { try {
@ -735,7 +735,7 @@ TEST(UtilTest, WindowsError) {
} }
TEST(UtilTest, ReportWindowsError) { TEST(UtilTest, ReportWindowsError) {
fmt::Writer out; fmt::MemoryWriter out;
fmt::internal::format_windows_error(out, ERROR_FILE_EXISTS, "test error"); fmt::internal::format_windows_error(out, ERROR_FILE_EXISTS, "test error");
out << '\n'; out << '\n';
EXPECT_WRITE(stderr, EXPECT_WRITE(stderr,