mirror of
https://github.com/priyanshujain/sanderling.git
synced 2026-10-02 19:17:10 +00:00
feat(cli): real doctor subcommand with adb/emulator/java checks
Each check is a value so tests can swap in fakes. Java check parses both legacy (1.8) and modern (17+) version strings. Emulator check falls back to ANDROID_HOME/emulator/emulator since the brew cask ships it without putting it on PATH.
This commit is contained in:
1 parent
63796fbd42
commit
b6b18c3681
4 files changed
+210
-7
No files matched your search
+2
-2
@@ -1,6 +1,7 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"errors"
|
||||
"flag"
|
||||
"fmt"
|
||||
@@ -66,8 +67,7 @@ func runTest(options testOptions, stdout io.Writer) error {
|
||||
}
|
||||
|
||||
func runDoctor(stdout io.Writer) error {
|
||||
fmt.Fprintln(stdout, "uatu doctor (stub): all checks pending implementation")
|
||||
return nil
|
||||
return runDoctorChecks(context.Background(), defaultDoctorChecks(), stdout)
|
||||
}
|
||||
|
||||
func run(args []string, stdout, stderr io.Writer) error {
|
||||
|
||||
Reference in new issue
Block a user