astyle formatting

[ci skip]
This commit is contained in:
Daniel Marjamäki 2018-05-14 22:48:37 +02:00
parent e8bc955023
commit 66599b4ade
1 changed files with 12 additions and 12 deletions

View File

@ -142,7 +142,7 @@ private:
TEST_CASE(inlineFunction); // #3989 TEST_CASE(inlineFunction); // #3989
TEST_CASE(smartPtrInContainer); // #8262 TEST_CASE(smartPtrInContainer); // #8262
} }
void check(const char code[], bool cpp = false) { void check(const char code[], bool cpp = false) {
@ -1523,17 +1523,17 @@ private:
ASSERT_EQUALS("", errout.str()); ASSERT_EQUALS("", errout.str());
} }
// #8262 // #8262
void smartPtrInContainer() { void smartPtrInContainer() {
check( "std::list< std::shared_ptr<int> > mList;\n" check("std::list< std::shared_ptr<int> > mList;\n"
"void test(){\n" "void test(){\n"
" int *pt = new int(1);\n" " int *pt = new int(1);\n"
" mList.push_back(std::shared_ptr<int>(pt));\n" " mList.push_back(std::shared_ptr<int>(pt));\n"
"}\n", "}\n",
true true
); );
TODO_ASSERT_EQUALS("", "[test.cpp:5]: (error) Memory leak: pt\n", errout.str()); TODO_ASSERT_EQUALS("", "[test.cpp:5]: (error) Memory leak: pt\n", errout.str());
} }
}; };