aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorhjk <hjk@qt.io>2018-03-21 14:56:59 +0100
committerhjk <hjk@qt.io>2018-03-22 13:05:38 +0000
commit401d6862b5f6e31d5ca4fe8ad9a2be9836dd0059 (patch)
tree3a88458d59f4cd61b0d9f1c267f9540ff59f11fa /tests
parent5068f9ac367bafd8683b653366b42bcac5a3baf1 (diff)
Debugger: Make CharArrays dumper test pass on linux
I need the #include <wchar.h> after a recent upgrade. Change-Id: I59790d6c92b14f42df8b5ece7227c406f2810c8b Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/debugger/tst_dumpers.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/tests/auto/debugger/tst_dumpers.cpp b/tests/auto/debugger/tst_dumpers.cpp
index 2009eb5ab8..2e15b15c88 100644
--- a/tests/auto/debugger/tst_dumpers.cpp
+++ b/tests/auto/debugger/tst_dumpers.cpp
@@ -1319,13 +1319,7 @@ void tst_Dumpers::dumper()
"\n#define BREAK qtcDebugBreakFunction();"
"\n\nvoid unused(const void *first,...) { (void) first; }"
"\n#else"
- "\n#include <stdint.h>"
- "\n#ifndef _WIN32"
- "\ntypedef char CHAR;"
- "\ntypedef char *PCHAR;"
- "\ntypedef wchar_t WCHAR;"
- "\ntypedef wchar_t *PWCHAR;"
- "\n#endif\n";
+ "\n#include <stdint.h>";
if (m_debuggerEngine == LldbEngine)
//#ifdef Q_OS_MAC
@@ -5230,7 +5224,11 @@ void tst_Dumpers::dumper_data()
QTest::newRow("CharArrays")
- << Data("",
+ << Data("#ifndef _WIN32\n"
+ "#include <wchar.h>\n"
+ "typedef char CHAR;\n"
+ "typedef wchar_t WCHAR;\n"
+ "#endif\n",
"char s[] = \"aöa\";\n"
"char t[] = \"aöax\";\n"
"wchar_t w[] = L\"aöa\";\n"