unittests: removed not needed '\n' at the end of testcases.

This commit is contained in:
Ettl Martin 2013-03-19 09:18:58 +01:00
parent 7c0905cd4e
commit 54d398c7dd
7 changed files with 329 additions and 329 deletions

View File

@ -63,7 +63,7 @@ private:
check("void foo()\n"
"{\n"
" a = p;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -72,28 +72,28 @@ private:
"{\n"
" int a = p;\n"
" return a + 4;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (portability) Assigning a pointer to an integer is not portable.\n", errout.str());
check("int foo(int p[])\n"
"{\n"
" int a = p;\n"
" return a + 4;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (portability) Assigning a pointer to an integer is not portable.\n", errout.str());
check("int foo(int p[])\n"
"{\n"
" int *a = p;\n"
" return a;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (portability) Returning an address value in a function with integer return type is not portable.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" int *p = x;\n"
" *p = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (portability) Assigning an integer to a pointer is not portable.\n", errout.str());
check("int f(const char *p) {\n" // #4659
@ -106,7 +106,7 @@ private:
check("struct Foo { int *p };\n"
"void f(struct Foo *foo) {\n"
" int i = foo->p;\n"
"}\n");
"}");
TODO_ASSERT_EQUALS("[test.cpp:3]: (portability) Assigning a pointer to an integer is not portable.\n", "", errout.str());
}
@ -114,7 +114,7 @@ private:
// Ticket #2892
check("void foo(int *p) {\n"
" int a = (p != NULL);\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -123,62 +123,62 @@ private:
check("void foo(int *p) {\n"
" int x = 10;\n"
" int *a = p + x;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("void foo(int *p) {\n"
" int x = 10;\n"
" int *a = x + p;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("void foo(int *p) {\n"
" int x = 10;\n"
" int *a = x * x;\n"
"}\n");
"}");
TODO_ASSERT_EQUALS("error", "", errout.str());
check("void foo(int *start, int *end) {\n"
" int len;\n"
" int len = end + 10 - start;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
void returnIssues() {
check("void* foo(int i) {\n"
" return i;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:2]: (portability) Returning an integer in a function with pointer return type is not portable.\n", errout.str());
check("void* foo(int* i) {\n"
" return i;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("void* foo() {\n"
" return 0;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("int foo(int i) {\n"
" return i;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("int foo(char* c) {\n"
" return c;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:2]: (portability) Returning an address value in a function with integer return type is not portable.\n", errout.str());
check("int foo(char* c) {\n"
" return 1+c;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:2]: (portability) Returning an address value in a function with integer return type is not portable.\n", errout.str());
check("std::string foo(char* c) {\n"
" return c;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("int foo(char *a, char *b) {\n" // #4486

View File

@ -65,14 +65,14 @@ private:
"{\n"
" int y = x & 4;\n"
" if (y == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3] -> [test.cpp:4]: (style) Mismatching assignment and comparison, comparison 'y==3' is always false.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" int y = x & 4;\n"
" if (y != 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3] -> [test.cpp:4]: (style) Mismatching assignment and comparison, comparison 'y!=3' is always true.\n", errout.str());
// |
@ -105,13 +105,13 @@ private:
check("void foo(int x) {\n"
" int y = x & 4;\n"
" if ((y == 3) && (z == 1));\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:2] -> [test.cpp:3]: (style) Mismatching assignment and comparison, comparison 'y==3' is always false.\n", errout.str());
check("void foo(int x) {\n"
" int y = x & 4;\n"
" if ((x==123) || ((y == 3) && (z == 1)));\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:2] -> [test.cpp:3]: (style) Mismatching assignment and comparison, comparison 'y==3' is always false.\n", errout.str());
check("void f(int x) {\n"
@ -183,52 +183,52 @@ private:
check("void foo(int x)\n"
"{\n"
" if (x & 4 == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X & 0x4) == 0x3' is always false.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" if ((x & 4) == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X & 0x4) == 0x3' is always false.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" if (x & 4 != 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X & 0x4) != 0x3' is always true.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" if ((x | 4) == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X | 0x4) == 0x3' is always false.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" if ((x | 4) != 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X | 0x4) != 0x3' is always true.\n", errout.str());
// array
check("void foo(int *x)\n"
"{\n"
" if (x[0] & 4 == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X & 0x4) == 0x3' is always false.\n", errout.str());
// struct member
check("void foo(struct X *x)\n"
"{\n"
" if (x->y & 4 == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X & 0x4) == 0x3' is always false.\n", errout.str());
// expression
check("void foo(int x)\n"
"{\n"
" if ((x+2) & 4 == 3);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (style) Expression '(X & 0x4) == 0x3' is always false.\n", errout.str());
}
@ -237,14 +237,14 @@ private:
"{\n"
" if (x & 7);\n"
" else if (x == 1);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (style) Expression is always false because 'else if' condition matches previous condition at line 3.\n", errout.str());
check("void foo(int x)\n"
"{\n"
" if (x & 7);\n"
" else if (x & 1);\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (style) Expression is always false because 'else if' condition matches previous condition at line 3.\n", errout.str());
}
};

View File

@ -371,7 +371,7 @@ private:
"{\n"
" extern struct foo f;\n"
" return &f;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -409,7 +409,7 @@ private:
" abc(0, psz_title);\n"
" free(psz_title);\n"
" }\n"
"}\n");
"}");
ASSERT_EQUALS(std::string(""), errout.str());
}
@ -417,7 +417,7 @@ private:
check("void f(EventPtr *eventP, ActionPtr **actionsP) {\n"
" EventPtr event = *eventP;\n"
" *actionsP = &event->actions;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -425,7 +425,7 @@ private:
check("static void function(unsigned long **datap) {\n"
" struct my_s *mr = global_structure_pointer;\n"
" *datap = &mr->value;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -434,7 +434,7 @@ private:
"{\n"
" char str[100] = {0};\n"
" return str;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (error) Pointer to local array variable returned.\n", errout.str());
check("class Fred {\n"
@ -444,7 +444,7 @@ private:
"{\n"
" char str[100] = {0};\n"
" return str;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:7]: (error) Pointer to local array variable returned.\n", errout.str());
}
@ -453,7 +453,7 @@ private:
"{\n"
" char str[100] = {0};\n"
" return str;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("class Fred {\n"
@ -463,7 +463,7 @@ private:
"{\n"
" char str[100] = {0};\n"
" return str;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -472,21 +472,21 @@ private:
"{\n"
" std::string s;\n"
" return s;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (error) Reference to auto variable returned.\n", errout.str());
check("std::vector<int> &foo()\n"
"{\n"
" std::vector<int> v;\n"
" return v;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (error) Reference to auto variable returned.\n", errout.str());
check("std::vector<int> &foo()\n"
"{\n"
" static std::vector<int> v;\n"
" return v;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("std::string hello()\n"
@ -497,7 +497,7 @@ private:
"std::string &f()\n"
"{\n"
" return hello();\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:8]: (error) Reference to temporary returned.\n", errout.str());
// make sure scope is used in function lookup
@ -572,7 +572,7 @@ private:
"{\n"
" std::string s;\n"
" return s;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:7]: (error) Reference to auto variable returned.\n", errout.str());
check("class Fred {\n"
@ -582,7 +582,7 @@ private:
"{\n"
" std::vector<int> v;\n"
" return v;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:7]: (error) Reference to auto variable returned.\n", errout.str());
check("class Fred {\n"
@ -592,7 +592,7 @@ private:
"{\n"
" static std::vector<int> v;\n"
" return v;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("class Fred {\n"
@ -605,7 +605,7 @@ private:
"std::string &Fred::f()\n"
"{\n"
" return hello();\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:10]: (error) Reference to temporary returned.\n", errout.str());
check("class Fred {\n"
@ -619,7 +619,7 @@ private:
"std::string &Fred::f()\n"
"{\n"
" return hello();\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:11]: (error) Reference to temporary returned.\n", errout.str());
check("class Bar;\n"
@ -659,7 +659,7 @@ private:
" double ret = getValue();\n"
" rd = ret;\n"
" return rd;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -669,7 +669,7 @@ private:
"double & f() {\n"
" double & ref = a;\n"
" return ref;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -736,21 +736,21 @@ private:
check("int* foo(int y)\n"
"{\n"
" return &y;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (error) Address of function parameter 'y' returned.\n", errout.str());
check("int ** foo(int * y)\n"
"{\n"
" return &y;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:3]: (error) Address of function parameter 'y' returned.\n", errout.str());
check("const int * foo(const int & y)\n"
"{\n"
" return &y;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}

View File

@ -1196,7 +1196,7 @@ private:
" m_x[1] = 0;\n"
" }\n"
" int m_x[1];\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:7]: (error) Array 'm_x[1]' accessed at index 1, which is out of bounds.\n", errout.str());
}
@ -3788,7 +3788,7 @@ private:
" }\n"
"\n"
" int arr[2*BSize + 2];\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}

View File

@ -68,7 +68,7 @@ private:
"{\n"
" unsigned char ch = 0x80;\n"
" buf[ch] = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
check("int buf[256];\n"
@ -76,7 +76,7 @@ private:
"{\n"
" char ch = 0x80;\n"
" buf[ch] = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:5]: (warning) Signed 'char' type used as array index.\n", errout.str());
check("int buf[256];\n"
@ -84,20 +84,20 @@ private:
"{\n"
" signed char ch = 0x80;\n"
" buf[ch] = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:5]: (warning) Signed 'char' type used as array index.\n", errout.str());
check("int buf[256];\n"
"void foo(char ch)\n"
"{\n"
" buf[ch] = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:4]: (warning) Signed 'char' type used as array index.\n", errout.str());
check("void foo(const char str[])\n"
"{\n"
" map[str] = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -140,7 +140,7 @@ private:
" int result = 0;\n"
" char ch;\n"
" result = a | ch;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:5]: (warning) When using 'char' variables in bit operations, sign extension can generate unexpected results.\n", errout.str());
}
@ -149,14 +149,14 @@ private:
"{\n"
" char ch;\n"
" func(&ch);\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
void bitop3() {
check("void f(int& i, char& c) {\n"
" i &= c;\n"
"}\n");
"}");
ASSERT_EQUALS("[test.cpp:2]: (warning) When using 'char' variables in bit operations, sign extension can generate unexpected results.\n", errout.str());
}
@ -165,7 +165,7 @@ private:
"{\n"
" char c;\n"
" return &c;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -175,7 +175,7 @@ private:
"{\n"
" char c;\n"
" c = c & 0x123;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -184,7 +184,7 @@ private:
"{\n"
" char c;\n"
" int i = c & 0x03;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}

File diff suppressed because it is too large Load Diff

View File

@ -166,21 +166,21 @@ private:
"{\n"
"public:\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred\n"
"{\n"
"private:\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:1]: (style) The class 'Fred' does not have a constructor.\n", errout.str());
check("struct Fred\n"
"{\n"
"private:\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:1]: (style) The struct 'Fred' does not have a constructor.\n", errout.str());
}
@ -191,7 +191,7 @@ private:
"public:\n"
" Fred() : i(0) { }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred\n"
@ -199,7 +199,7 @@ private:
"public:\n"
" Fred() { i = 0; }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred\n"
@ -207,14 +207,14 @@ private:
"public:\n"
" Fred() { }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:4]: (warning) Member variable 'Fred::i' is not initialized in the constructor.\n", errout.str());
check("struct Fred\n"
"{\n"
" Fred() { }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:3]: (warning) Member variable 'Fred::i' is not initialized in the constructor.\n", errout.str());
}
@ -382,28 +382,28 @@ private:
" int x;\n"
"public:\n"
" Fred() noexcept;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred {\n"
" int x;\n"
"public:\n"
" Fred() noexcept(true);\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred {\n"
" int x;\n"
"public:\n"
" Fred() noexcept { x = 0; }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred {\n"
" int x;\n"
"public:\n"
" Fred() noexcept(true) { x = 0; }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -413,7 +413,7 @@ private:
" Fred()\n"
" { this->i = 0; }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -428,7 +428,7 @@ private:
" i = 1;\n"
" }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -484,7 +484,7 @@ private:
" Fred() { i = 0; }\n"
" void operator=(const Fred &fred) { }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:4]: (warning) Member variable 'Fred::i' is not assigned a value in 'Fred::operator='.\n", errout.str());
}
@ -496,7 +496,7 @@ private:
"private:\n"
" void Init() { i = 0; }\n"
" int i;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -513,7 +513,7 @@ private:
" }\n"
" return *this\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:6]: (warning) Member variable 'Fred::i' is not assigned a value in 'Fred::operator='.\n", errout.str());
check("class Fred\n"
@ -528,7 +528,7 @@ private:
" }\n"
" return *this\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:6]: (warning) Member variable 'Fred::i' is not assigned a value in 'Fred::operator='.\n", errout.str());
check("class Fred\n"
@ -543,7 +543,7 @@ private:
" }\n"
" return *this\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:6]: (warning) Member variable 'Fred::i' is not assigned a value in 'Fred::operator='.\n", errout.str());
check("class Fred\n"
@ -558,7 +558,7 @@ private:
" }\n"
" return *this\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -573,7 +573,7 @@ private:
" Fred(rhs).swap(*this);\n"
" return *this;\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -596,7 +596,7 @@ private:
" int b;\n"
" Fred() { b = 0; }\n"
" };\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
@ -616,7 +616,7 @@ private:
" int b;\n"
" Fred() { b = 0; }\n"
" };\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
@ -636,7 +636,7 @@ private:
" int b;\n"
" Fred() { b = 0; }\n"
" };\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
@ -658,7 +658,7 @@ private:
" Fred() { b = 0; }\n"
" };\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
@ -680,7 +680,7 @@ private:
" Fred() { }\n"
" };\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:7]: (warning) Member variable 'Fred::a' is not initialized in the constructor.\n"
"[test.cpp:16]: (warning) Member variable 'Fred::b' is not initialized in the constructor.\n", errout.str());
@ -700,7 +700,7 @@ private:
"c::c()\n"
"{\n"
" m_iMyInt1 = m_iMyInt2 = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -733,7 +733,7 @@ private:
"void c::InitInt()\n"
"{\n"
" m_iMyInt = 0;\n"
"}\n");
"}");
ASSERT_EQUALS("", errout.str());
}
@ -775,7 +775,7 @@ private:
"public:\n"
" Fred() { }\n"
" static void *p;\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -793,7 +793,7 @@ private:
" {\n"
" U.a = 0;\n"
" }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class Fred\n"
@ -807,7 +807,7 @@ private:
" Fred()\n"
" {\n"
" }\n"
"};\n");
"};");
TODO_ASSERT_EQUALS("[test.cpp:9]: (warning) Member variable 'Fred::U' is not initialized in the constructor.\n", "", errout.str());
}
@ -1013,7 +1013,7 @@ private:
" A(){}\n"
" A(const A&){}\n"
" const A& operator=(const A&){return *this;}\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class B\n"
@ -1029,7 +1029,7 @@ private:
" A(){}\n"
" A(const A&){}\n"
" const A& operator=(const A&){return *this;}\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:12]: (warning) Member variable 'A::m_SemVar' is not initialized in the constructor.\n"
"[test.cpp:13]: (warning) Member variable 'A::m_SemVar' is not assigned a value in 'A::operator='.\n", errout.str());
@ -1040,7 +1040,7 @@ private:
" A(){}\n"
" A(const A&){}\n"
" const A& operator=(const A&){return *this;}\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -1057,7 +1057,7 @@ private:
" A(){}\n"
" A(const A&){}\n"
" const A& operator=(const A&){return *this;}\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
check("class B\n"
@ -1073,7 +1073,7 @@ private:
" A(){}\n"
" A(const A&){}\n"
" const A& operator=(const A&){return *this;}\n"
"};\n");
"};");
ASSERT_EQUALS("[test.cpp:12]: (warning) Member variable 'A::m_SemVar' is not initialized in the constructor.\n"
"[test.cpp:13]: (warning) Member variable 'A::m_SemVar' is not assigned a value in 'A::operator='.\n", errout.str());
}
@ -1102,7 +1102,7 @@ private:
"public:\n"
" Fred() : var(0) {}\n"
" ~Fred() {}\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}
@ -1110,7 +1110,7 @@ private:
check("class something {\n"
" int * ( something :: * process()) () { return 0; }\n"
" something() { process(); }\n"
"};\n");
"};");
ASSERT_EQUALS("", errout.str());
}