Ticket #3581 - added missing newlines to the test code

This commit is contained in:
Zachary Blair 2012-02-04 11:33:48 -08:00
parent 8f827aa65f
commit 69567515ce
1 changed files with 20 additions and 20 deletions

View File

@ -4586,31 +4586,31 @@ private:
ASSERT_EQUALS("[test.cpp:4]: (error) Memory pointed to by 'p' is freed twice.\n", errout.str()); ASSERT_EQUALS("[test.cpp:4]: (error) Memory pointed to by 'p' is freed twice.\n", errout.str());
check( check(
"~LineMarker() {" "~LineMarker() {\n"
" delete pxpm;" " delete pxpm;\n"
"}" "}\n"
"LineMarker &operator=(const LineMarker &) {" "LineMarker &operator=(const LineMarker &) {\n"
" delete pxpm;" " delete pxpm;\n"
" pxpm = NULL;" " pxpm = NULL;\n"
" return *this;" " return *this;\n"
"}" "}"
); );
ASSERT_EQUALS("", errout.str()); ASSERT_EQUALS("", errout.str());
check( check(
"void bug()" "void foo()\n"
"{" "{\n"
" int* ptr = NULL;" " int* ptr = NULL;\n"
" try" " try\n"
" {" " {\n"
" ptr = new int(4);" " ptr = new int(4);\n"
" }" " }\n"
" catch(...)" " catch(...)\n"
" {" " {\n"
" delete ptr;" " delete ptr;\n"
" throw;" " throw;\n"
" }" " }\n"
" delete ptr;" " delete ptr;\n"
"}" "}"
); );
ASSERT_EQUALS("", errout.str()); ASSERT_EQUALS("", errout.str());