Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(131)

Unified Diff: tests/StringTest.cpp

Issue 1280853002: Fix StringTest for VS2015 (Closed) Base URL: https://skia.googlesource.com/skia.git@vs2015
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/StringTest.cpp
diff --git a/tests/StringTest.cpp b/tests/StringTest.cpp
index 13ee5ec2153ff6da775bef64887fc16f759da2f4..af21d861fe7d8d9d004a55744caacdcbcbb8ce97 100644
--- a/tests/StringTest.cpp
+++ b/tests/StringTest.cpp
@@ -156,7 +156,7 @@ DEF_TEST(String, reporter) {
{ SK_Scalar1, "1" },
{ -SK_Scalar1, "-1" },
{ SK_Scalar1/2, "0.5" },
- #ifdef SK_BUILD_FOR_WIN
+ #if defined(SK_BUILD_FOR_WIN) && (_MSC_VER < 1900)
{ 3.4028234e38f, "3.4028235e+038" },
{ -3.4028234e38f, "-3.4028235e+038" },
#else
@@ -168,8 +168,9 @@ DEF_TEST(String, reporter) {
a.reset();
a.appendScalar(gRec[i].fValue);
REPORTER_ASSERT(reporter, a.size() <= SkStrAppendScalar_MaxSize);
-// SkDebugf(" received <%s> expected <%s>\n", a.c_str(), gRec[i].fString);
- REPORTER_ASSERT(reporter, a.equals(gRec[i].fString));
+ if (!a.equals(gRec[i].fString)) {
+ ERRORF(reporter, "received <%s> expected <%s>\n", a.c_str(), gRec[i].fString);
+ }
}
REPORTER_ASSERT(reporter, SkStringPrintf("%i", 0).equals("0"));
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698