@@ -216,8 +216,9 @@ TEST_F(SpecialCaseListTest, NoTrigramsInARule) {
216216}
217217
218218TEST_F (SpecialCaseListTest, RepetitiveRule) {
219- std::unique_ptr<SpecialCaseList> SCL = makeSpecialCaseList (" fun:*bar*bar*bar*bar*\n "
220- " fun:bar*\n " );
219+ std::unique_ptr<SpecialCaseList> SCL =
220+ makeSpecialCaseList (" fun:*bar*bar*bar*bar*\n "
221+ " fun:bar*\n " );
221222 EXPECT_TRUE (SCL->inSection (" " , " fun" , " bara" ));
222223 EXPECT_FALSE (SCL->inSection (" " , " fun" , " abara" ));
223224 EXPECT_TRUE (SCL->inSection (" " , " fun" , " barbarbarbar" ));
@@ -226,7 +227,8 @@ TEST_F(SpecialCaseListTest, RepetitiveRule) {
226227}
227228
228229TEST_F (SpecialCaseListTest, SpecialSymbolRule) {
229- std::unique_ptr<SpecialCaseList> SCL = makeSpecialCaseList (" src:*c\\ +\\ +abi*\n " );
230+ std::unique_ptr<SpecialCaseList> SCL =
231+ makeSpecialCaseList (" src:*c\\ +\\ +abi*\n " );
230232 EXPECT_TRUE (SCL->inSection (" " , " src" , " c++abi" ));
231233 EXPECT_FALSE (SCL->inSection (" " , " src" , " c\\ +\\ +abi" ));
232234}
@@ -242,8 +244,9 @@ TEST_F(SpecialCaseListTest, PopularTrigram) {
242244}
243245
244246TEST_F (SpecialCaseListTest, EscapedSymbols) {
245- std::unique_ptr<SpecialCaseList> SCL = makeSpecialCaseList (" src:*c\\ +\\ +abi*\n "
246- " src:*hello\\\\ world*\n " );
247+ std::unique_ptr<SpecialCaseList> SCL =
248+ makeSpecialCaseList (" src:*c\\ +\\ +abi*\n "
249+ " src:*hello\\\\ world*\n " );
247250 EXPECT_TRUE (SCL->inSection (" " , " src" , " dir/c++abi" ));
248251 EXPECT_FALSE (SCL->inSection (" " , " src" , " dir/c\\ +\\ +abi" ));
249252 EXPECT_FALSE (SCL->inSection (" " , " src" , " c\\ +\\ +abi" ));
@@ -315,17 +318,19 @@ TEST_F(SpecialCaseListTest, Version3) {
315318 " src:def\n "
316319 " [sect2]\n "
317320 " src:def\n "
318- " src:def\n " );
321+ " src:def\n "
322+ " [sect1]\n "
323+ " src:foo*\n " );
319324 EXPECT_TRUE (SCL->inSection (" sect1" , " src" , " fooz" ));
320325 EXPECT_TRUE (SCL->inSection (" sect1" , " src" , " barz" ));
321326 EXPECT_FALSE (SCL->inSection (" sect2" , " src" , " fooz" ));
322327
323328 EXPECT_TRUE (SCL->inSection (" sect2" , " src" , " def" ));
324329 EXPECT_TRUE (SCL->inSection (" sect1" , " src" , " def" ));
325330
326- EXPECT_EQ (2u , SCL->inSectionBlame (" sect1" , " src" , " fooz" ));
327331 EXPECT_EQ (4u , SCL->inSectionBlame (" sect1" , " src" , " barz" ));
328332 EXPECT_EQ (5u , SCL->inSectionBlame (" sect1" , " src" , " def" ));
329333 EXPECT_EQ (8u , SCL->inSectionBlame (" sect2" , " src" , " def" ));
334+ EXPECT_EQ (10u , SCL->inSectionBlame (" sect1" , " src" , " fooz" ));
330335}
331- }
336+ } // namespace
0 commit comments