Changeset View
Changeset View
Standalone View
Standalone View
plugins/gdb/unittests/test_gdbprinters.cpp
Show First 20 Lines • Show All 96 Lines • ▼ Show 20 Line(s) | 33 | public: | |||
---|---|---|---|---|---|
97 | } | 97 | } | ||
98 | }; | 98 | }; | ||
99 | 99 | | |||
100 | void QtPrintersTest::testQString() | 100 | void QtPrintersTest::testQString() | ||
101 | { | 101 | { | ||
102 | GdbProcess gdb(QStringLiteral("debuggee_qstring")); | 102 | GdbProcess gdb(QStringLiteral("debuggee_qstring")); | ||
103 | gdb.execute("break qstring.cpp:5"); | 103 | gdb.execute("break qstring.cpp:5"); | ||
104 | gdb.execute("run"); | 104 | gdb.execute("run"); | ||
105 | QVERIFY(gdb.execute("print s").contains("\"test string\"")); | 105 | QVERIFY(gdb.execute("print s").contains("\"test最后一个不是特殊字符'\\\"\\\\u6211\"")); | ||
106 | gdb.execute("next"); | 106 | gdb.execute("next"); | ||
107 | QVERIFY(gdb.execute("print s").contains("\"test stringx\"")); | 107 | QVERIFY(gdb.execute("print s").contains("\"test最后一个不是特殊字符'\\\"\\\\u6211x\"")); | ||
108 | } | 108 | } | ||
109 | 109 | | |||
110 | void QtPrintersTest::testQByteArray() | 110 | void QtPrintersTest::testQByteArray() | ||
111 | { | 111 | { | ||
112 | GdbProcess gdb(QStringLiteral("debuggee_qbytearray")); | 112 | GdbProcess gdb(QStringLiteral("debuggee_qbytearray")); | ||
113 | gdb.execute("break qbytearray.cpp:5"); | 113 | gdb.execute("break qbytearray.cpp:5"); | ||
114 | gdb.execute("run"); | 114 | gdb.execute("run"); | ||
115 | QByteArray out = gdb.execute("print ba"); | 115 | QByteArray out = gdb.execute("print ba"); | ||
▲ Show 20 Lines • Show All 354 Lines • Show Last 20 Lines |