Preprocessor: updated tests

This commit is contained in:
Daniel Marjamäki 2011-10-24 21:56:43 +02:00
parent 3413ffef3e
commit f0d8fd7235
1 changed files with 3 additions and 3 deletions

View File

@ -2866,7 +2866,7 @@ private:
const std::string code("#ifndef X\n#define X\n123\n#endif\n"
"#ifndef X\n#define X\n123\n#endif\n");
const std::string actual(preprocessor.handleIncludes(code,filePath,includePaths,defs));
ASSERT_EQUALS("\n\n123\n\n" "\n\n\n\n", actual);
ASSERT_EQUALS("\n#define X\n123\n\n" "\n\n\n\n", actual);
}
// #define => #if
@ -2877,7 +2877,7 @@ private:
"456\n"
"#endif\n");
const std::string actual(preprocessor.handleIncludes(code,filePath,includePaths,defs));
ASSERT_EQUALS("\n\n456\n\n", actual);
ASSERT_EQUALS("#define X 123\n\n456\n\n", actual);
}
// #elif
@ -2926,7 +2926,7 @@ private:
defs.clear();
const std::string actual(preprocessor.handleIncludes(code + "#undef X\n" + code, filePath, includePaths, defs));
ASSERT_EQUALS(actual1 + "\n" + actual1, actual);
ASSERT_EQUALS(actual1 + "#undef X\n" + actual1, actual);
}
}
};