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

Unified Diff: tests/StringTest.cpp

Issue 88773002: DM: write failed comparison mode .pngs one more level deep in the tree. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: depth() instead Created 7 years, 1 month 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 | « src/core/SkString.cpp ('k') | 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 462fcfadafd58f4e2d8949fa504438a5869e99f0..c8c10e192554fa421e94b474bf5d207e664d37fc 100644
--- a/tests/StringTest.cpp
+++ b/tests/StringTest.cpp
@@ -192,3 +192,16 @@ static void TestString(skiatest::Reporter* reporter) {
#include "TestClassDef.h"
DEFINE_TESTCLASS("String", StringTestClass, TestString)
+
+DEF_TEST(String_SkStrSplit, r) {
+ SkTArray<SkString> results;
+
+ SkStrSplit("a-_b_c-dee--f-_-_-g-", "-_", &results);
+ REPORTER_ASSERT(r, results.count() == 6);
+ REPORTER_ASSERT(r, results[0].equals("a"));
+ REPORTER_ASSERT(r, results[1].equals("b"));
+ REPORTER_ASSERT(r, results[2].equals("c"));
+ REPORTER_ASSERT(r, results[3].equals("dee"));
+ REPORTER_ASSERT(r, results[4].equals("f"));
+ REPORTER_ASSERT(r, results[5].equals("g"));
+}
« no previous file with comments | « src/core/SkString.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698