Procházet zdrojové kódy

internal/driver: ignore temp dir error on Android (#295)

On an instance of the Android emulator running x86_64, $HOME points
to / which is not writable. Add Android to the list of GOOS where
the temp dir error is skipped.

Fixes the android/amd64 and android/386 builders on build.golang.org.
Elias Naur před 7 roky
rodič
revize
0138a3cd6d
1 změnil soubory, kde provedl 3 přidání a 1 odebrání
  1. 3
    1
      internal/driver/fetch_test.go

+ 3
- 1
internal/driver/fetch_test.go Zobrazit soubor

@@ -412,8 +412,10 @@ func TestHttpsInsecure(t *testing.T) {
412 412
 		Symbolize: "remote",
413 413
 	}
414 414
 	rx := "Saved profile in"
415
-	if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") {
415
+	if runtime.GOOS == "darwin" && (runtime.GOARCH == "arm" || runtime.GOARCH == "arm64") ||
416
+		runtime.GOOS == "android" {
416 417
 		// On iOS, $HOME points to the app root directory and is not writable.
418
+		// On Android, $HOME points to / which is not writable.
417 419
 		rx += "|Could not use temp dir"
418 420
 	}
419 421
 	o := &plugin.Options{