• Home
  • Raw
  • Download

Lines Matching refs:theString

29   StringType theString;  member in __anone928286f0111::SmallStringTest
43 assertEmpty(theString); in TEST_F()
44 EXPECT_TRUE(theString.rbegin() == theString.rend()); in TEST_F()
48 theString.assign(3, 'a'); in TEST_F()
49 EXPECT_EQ(3u, theString.size()); in TEST_F()
50 EXPECT_STREQ("aaa", theString.c_str()); in TEST_F()
55 theString.assign(abc.begin(), abc.end()); in TEST_F()
56 EXPECT_EQ(3u, theString.size()); in TEST_F()
57 EXPECT_STREQ("abc", theString.c_str()); in TEST_F()
62 theString.assign(abc); in TEST_F()
63 EXPECT_EQ(3u, theString.size()); in TEST_F()
64 EXPECT_STREQ("abc", theString.c_str()); in TEST_F()
70 theString.assign(abcVec); in TEST_F()
71 EXPECT_EQ(3u, theString.size()); in TEST_F()
72 EXPECT_STREQ("abc", theString.c_str()); in TEST_F()
77 theString.append(abc.begin(), abc.end()); in TEST_F()
78 theString.append(abc.begin(), abc.end()); in TEST_F()
79 EXPECT_EQ(6u, theString.size()); in TEST_F()
80 EXPECT_STREQ("abcabc", theString.c_str()); in TEST_F()
85 theString.append(abc); in TEST_F()
86 theString.append(abc); in TEST_F()
87 EXPECT_EQ(6u, theString.size()); in TEST_F()
88 EXPECT_STREQ("abcabc", theString.c_str()); in TEST_F()
94 theString.append(abcVec); in TEST_F()
95 theString.append(abcVec); in TEST_F()
96 EXPECT_EQ(6u, theString.size()); in TEST_F()
97 EXPECT_STREQ("abcabc", theString.c_str()); in TEST_F()
101 theString = "hello"; in TEST_F()
102 EXPECT_EQ("lo", theString.substr(3)); in TEST_F()
103 EXPECT_EQ("", theString.substr(100)); in TEST_F()
104 EXPECT_EQ("hello", theString.substr(0, 100)); in TEST_F()
105 EXPECT_EQ("o", theString.substr(4, 10)); in TEST_F()
109 theString = "hello"; in TEST_F()
110 EXPECT_EQ("l", theString.slice(2, 3)); in TEST_F()
111 EXPECT_EQ("ell", theString.slice(1, 4)); in TEST_F()
112 EXPECT_EQ("llo", theString.slice(2, 100)); in TEST_F()
113 EXPECT_EQ("", theString.slice(2, 1)); in TEST_F()
114 EXPECT_EQ("", theString.slice(10, 20)); in TEST_F()
118 theString = "hello"; in TEST_F()
119 EXPECT_EQ(2U, theString.find('l')); in TEST_F()
120 EXPECT_EQ(StringRef::npos, theString.find('z')); in TEST_F()
121 EXPECT_EQ(StringRef::npos, theString.find("helloworld")); in TEST_F()
122 EXPECT_EQ(0U, theString.find("hello")); in TEST_F()
123 EXPECT_EQ(1U, theString.find("ello")); in TEST_F()
124 EXPECT_EQ(StringRef::npos, theString.find("zz")); in TEST_F()
125 EXPECT_EQ(2U, theString.find("ll", 2)); in TEST_F()
126 EXPECT_EQ(StringRef::npos, theString.find("ll", 3)); in TEST_F()
127 EXPECT_EQ(0U, theString.find("")); in TEST_F()
129 EXPECT_EQ(3U, theString.rfind('l')); in TEST_F()
130 EXPECT_EQ(StringRef::npos, theString.rfind('z')); in TEST_F()
131 EXPECT_EQ(StringRef::npos, theString.rfind("helloworld")); in TEST_F()
132 EXPECT_EQ(0U, theString.rfind("hello")); in TEST_F()
133 EXPECT_EQ(1U, theString.rfind("ello")); in TEST_F()
134 EXPECT_EQ(StringRef::npos, theString.rfind("zz")); in TEST_F()
136 EXPECT_EQ(2U, theString.find_first_of('l')); in TEST_F()
137 EXPECT_EQ(1U, theString.find_first_of("el")); in TEST_F()
138 EXPECT_EQ(StringRef::npos, theString.find_first_of("xyz")); in TEST_F()
140 EXPECT_EQ(1U, theString.find_first_not_of('h')); in TEST_F()
141 EXPECT_EQ(4U, theString.find_first_not_of("hel")); in TEST_F()
142 EXPECT_EQ(StringRef::npos, theString.find_first_not_of("hello")); in TEST_F()
144 theString = "hellx xello hell ello world foo bar hello"; in TEST_F()
145 EXPECT_EQ(36U, theString.find("hello")); in TEST_F()
146 EXPECT_EQ(28U, theString.find("foo")); in TEST_F()
147 EXPECT_EQ(12U, theString.find("hell", 2)); in TEST_F()
148 EXPECT_EQ(0U, theString.find("")); in TEST_F()
152 theString = "hello"; in TEST_F()
153 EXPECT_EQ(2U, theString.count('l')); in TEST_F()
154 EXPECT_EQ(1U, theString.count('o')); in TEST_F()
155 EXPECT_EQ(0U, theString.count('z')); in TEST_F()
156 EXPECT_EQ(0U, theString.count("helloworld")); in TEST_F()
157 EXPECT_EQ(1U, theString.count("hello")); in TEST_F()
158 EXPECT_EQ(1U, theString.count("ello")); in TEST_F()
159 EXPECT_EQ(0U, theString.count("zz")); in TEST_F()
163 theString = "abcd"; in TEST_F()
164 theString.reserve(100); in TEST_F()
165 EXPECT_EQ("abcd", theString); in TEST_F()
167 theString.reserve(N); in TEST_F()
169 theString.push_back('y'); in TEST_F()
170 EXPECT_EQ("abcdyyy", theString.slice(0, 7)); in TEST_F()