summaryrefslogtreecommitdiffstats
path: root/src/tools
diff options
context:
space:
mode:
authorAssam Boudjelthia <assam.boudjelthia@qt.io>2021-06-18 12:54:55 +0000
committerAssam Boudjelthia <assam.boudjelthia@qt.io>2021-07-01 13:29:43 +0000
commit705877682eeab716f640f1cf78c22655fdca4b0e (patch)
tree92ba23023099c2db48907a3e0728d993c08e6425 /src/tools
parent41b7580164cc6d5454c0ec1271b146fddc6c1726 (diff)
Revert "Android: fix androidtestrunner passing when output file doesn't exist"
This reverts commit 1365a1c7a76a73838909d63acb60ebdfcbdff62e. Reason for revert: Causes the issue in QTBUG-94445. Pick-to: 6.2 Task-number: QTBUG-88508 Fixes: QTBUG-94445 Change-Id: I131234c9b1daeecd5f5f4921a9150d65a26db972 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/androidtestrunner/main.cpp13
1 files changed, 1 insertions, 12 deletions
diff --git a/src/tools/androidtestrunner/main.cpp b/src/tools/androidtestrunner/main.cpp
index 45b1b6202e..e0a69bb9cb 100644
--- a/src/tools/androidtestrunner/main.cpp
+++ b/src/tools/androidtestrunner/main.cpp
@@ -415,21 +415,10 @@ static bool pullFiles()
bool ret = true;
for (auto it = g_options.outFiles.constBegin(); it != g_options.outFiles.end(); ++it) {
QByteArray output;
-
- // If the output file doesn't exist, adb still returns 0 exit code.
- // Thus we need to explicitly check "echo $?".
- if (!execCommand(QStringLiteral("%1 shell \'run-as %2 cat files/output.%3; echo $?\'")
+ if (!execCommand(QStringLiteral("%1 shell run-as %2 cat files/output.%3")
.arg(g_options.adbCommand, g_options.package, it.key()), &output)) {
return false;
}
-
- // Handle the exit code then remove it from the output.
- bool ok;
- int ret = output.right(3).toInt(&ok);
- if (ret || !ok)
- return false;
-
- output.chop(3);
auto checkerIt = g_options.checkFiles.find(it.key());
ret = ret && checkerIt != g_options.checkFiles.end() && checkerIt.value()(output);
if (it.value() == QStringLiteral("-")){