about summary refs log tree commit diff
path: root/absl/strings/str_split_test.cc
diff options
context:
space:
mode:
Diffstat (limited to 'absl/strings/str_split_test.cc')
-rw-r--r--absl/strings/str_split_test.cc26
1 files changed, 13 insertions, 13 deletions
diff --git a/absl/strings/str_split_test.cc b/absl/strings/str_split_test.cc
index 16b047a1de85..c172a7629933 100644
--- a/absl/strings/str_split_test.cc
+++ b/absl/strings/str_split_test.cc
@@ -154,8 +154,8 @@ TEST(Split, APIExamples) {
   {
     // Uses the SkipWhitespace predicate.
     using absl::SkipWhitespace;
-    std::vector<std::string> v = absl::StrSplit("a, ,,b,", ',', SkipWhitespace());
-    EXPECT_THAT(v, ElementsAre("a", "b"));
+    std::vector<std::string> v = absl::StrSplit(" a , ,,b,", ',', SkipWhitespace());
+    EXPECT_THAT(v, ElementsAre(" a ", "b"));
   }
 
   {
@@ -241,10 +241,10 @@ TEST(SplitIterator, Basics) {
 
   EXPECT_NE(it, end);
   EXPECT_EQ("a", *it);  // tests dereference
-  ++it;  // tests preincrement
+  ++it;                 // tests preincrement
   EXPECT_NE(it, end);
   EXPECT_EQ("b", std::string(it->data(), it->size()));  // tests dereference as ptr
-  it++;  // tests postincrement
+  it++;                                            // tests postincrement
   EXPECT_EQ(it, end);
 }
 
@@ -265,10 +265,10 @@ TEST(SplitIterator, Predicate) {
 
   EXPECT_NE(it, end);
   EXPECT_EQ("a", *it);  // tests dereference
-  ++it;  // tests preincrement -- "b" should be skipped here.
+  ++it;                 // tests preincrement -- "b" should be skipped here.
   EXPECT_NE(it, end);
   EXPECT_EQ("c", std::string(it->data(), it->size()));  // tests dereference as ptr
-  it++;  // tests postincrement
+  it++;                                            // tests postincrement
   EXPECT_EQ(it, end);
 }
 
@@ -278,13 +278,13 @@ TEST(SplitIterator, EdgeCases) {
     std::string in;
     std::vector<std::string> expect;
   } specs[] = {
-    {"", {""}},
-    {"foo", {"foo"}},
-    {",", {"", ""}},
-    {",foo", {"", "foo"}},
-    {"foo,", {"foo", ""}},
-    {",foo,", {"", "foo", ""}},
-    {"foo,bar", {"foo", "bar"}},
+      {"", {""}},
+      {"foo", {"foo"}},
+      {",", {"", ""}},
+      {",foo", {"", "foo"}},
+      {"foo,", {"foo", ""}},
+      {",foo,", {"", "foo", ""}},
+      {"foo,bar", {"foo", "bar"}},
   };
 
   for (const auto& spec : specs) {