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

Side by Side Diff: tests/StringTest.cpp

Issue 27044002: Clean up SkTypes.h. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: For patch -p1. Created 7 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tests/PathOpsQuadReduceOrderTest.cpp ('k') | tests/WArrayTest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 #include "Test.h" 8 #include "Test.h"
9 #include "SkString.h" 9 #include "SkString.h"
10 #include <stdarg.h> 10 #include <stdarg.h>
11 11 #include <stdio.h>
12 12
13 // Windows vsnprintf doesn't 0-terminate safely), but is so far 13 // Windows vsnprintf doesn't 0-terminate safely), but is so far
14 // encapsulated in SkString that we can't test it directly. 14 // encapsulated in SkString that we can't test it directly.
15 15
16 #ifdef SK_BUILD_FOR_WIN 16 #ifdef SK_BUILD_FOR_WIN
17 #define VSNPRINTF(buffer, size, format, args) \ 17 #define VSNPRINTF(buffer, size, format, args) \
18 vsnprintf_s(buffer, size, _TRUNCATE, format, args) 18 vsnprintf_s(buffer, size, _TRUNCATE, format, args)
19 #else 19 #else
20 #define VSNPRINTF vsnprintf 20 #define VSNPRINTF vsnprintf
21 #endif 21 #endif
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 REPORTER_ASSERT(reporter, buffer[20] == 'a'); 185 REPORTER_ASSERT(reporter, buffer[20] == 'a');
186 printfAnalog(buffer, 20, "%30d", 0); 186 printfAnalog(buffer, 20, "%30d", 0);
187 REPORTER_ASSERT(reporter, buffer[18] == ' '); 187 REPORTER_ASSERT(reporter, buffer[18] == ' ');
188 REPORTER_ASSERT(reporter, buffer[19] == 0); 188 REPORTER_ASSERT(reporter, buffer[19] == 0);
189 REPORTER_ASSERT(reporter, buffer[20] == 'a'); 189 REPORTER_ASSERT(reporter, buffer[20] == 'a');
190 190
191 } 191 }
192 192
193 #include "TestClassDef.h" 193 #include "TestClassDef.h"
194 DEFINE_TESTCLASS("String", StringTestClass, TestString) 194 DEFINE_TESTCLASS("String", StringTestClass, TestString)
OLDNEW
« no previous file with comments | « tests/PathOpsQuadReduceOrderTest.cpp ('k') | tests/WArrayTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698