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

Unified Diff: Source/platform/text/SegmentedStringTest.cpp

Issue 1308573006: [reland] SegmentedString::push() should always push a char in front (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix test / accept yosin@ suggestion 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 | « Source/platform/text/SegmentedString.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/text/SegmentedStringTest.cpp
diff --git a/Source/platform/text/SegmentedStringTest.cpp b/Source/platform/text/SegmentedStringTest.cpp
index b033bd5f7170c55ae6b6110e6f584c7558f5e8c1..5aec779fbef16d4e0d8e8e5311053eefb0524bfa 100644
--- a/Source/platform/text/SegmentedStringTest.cpp
+++ b/Source/platform/text/SegmentedStringTest.cpp
@@ -47,20 +47,18 @@ TEST(SegmentedStringTest, CurrentChar)
EXPECT_EQ('c', copied.currentChar());
EXPECT_EQ('c', assigned.currentChar());
}
- original.push('a');
+ original.push('b');
{
SegmentedString copied(original);
SegmentedString assigned;
assigned = original;
- EXPECT_EQ("acde", original.toString());
- EXPECT_EQ('a', original.currentChar());
- EXPECT_EQ('a', copied.currentChar());
- EXPECT_EQ('a', assigned.currentChar());
+ EXPECT_EQ("bcde", original.toString());
+ EXPECT_EQ('b', original.currentChar());
+ EXPECT_EQ('b', copied.currentChar());
+ EXPECT_EQ('b', assigned.currentChar());
}
- original.push('b');
+ original.push('a');
{
- // Two consecutive push means to push the second char *after* the
- // first char in SegmentedString.
SegmentedString copied(original);
SegmentedString assigned;
assigned = original;
« no previous file with comments | « Source/platform/text/SegmentedString.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698