Skip to content

Commit

Permalink
ci: Read test output from stderr
Browse files Browse the repository at this point in the history
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
  • Loading branch information
JohnTitor committed Nov 19, 2022
1 parent bbf929d commit 0d37343
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ci/runtest-android.rs
Expand Up @@ -22,7 +22,7 @@ fn main() {
.arg(&test)
.arg(&dst)
.status()
.expect("failed to run: adb pushr");
.expect("failed to run: adb push");
assert!(status.success());

let output = Command::new("adb")
Expand All @@ -38,8 +38,8 @@ fn main() {
String::from_utf8_lossy(&output.stdout),
String::from_utf8_lossy(&output.stderr));

let stdout = String::from_utf8_lossy(&output.stdout);
stdout.lines().find(|l|
let stderr = String::from_utf8_lossy(&output.stderr);
stderr.lines().find(|l|
(l.starts_with("PASSED ") && l.contains(" tests")) ||
l.starts_with("test result: ok")
).unwrap_or_else(|| {
Expand Down

0 comments on commit 0d37343

Please sign in to comment.