diff options
author | Ivan Lozano <ivanlozano@google.com> | 2019-09-03 13:49:39 -0700 |
---|---|---|
committer | Ivan Lozano <ivanlozano@google.com> | 2019-09-03 13:57:36 -0700 |
commit | c0083614f6ed11ceb0ae71ed4cf4b08667be3e4b (patch) | |
tree | 17735f0319d449087f51e3a835fae67857bbbbc1 /rust/rust_test.go | |
parent | 3f3190fe4a4bd6018ab55a8f40bc2f78818e8fe8 (diff) | |
download | build_soong-c0083614f6ed11ceb0ae71ed4cf4b08667be3e4b.tar.gz build_soong-c0083614f6ed11ceb0ae71ed4cf4b08667be3e4b.tar.bz2 build_soong-c0083614f6ed11ceb0ae71ed4cf4b08667be3e4b.zip |
Do not run Soong tests for Rust on non-Linux hosts.
The Rust toolchain only supports Linux hosts, so skip Rust tests
that depend on host toolchains when building on other platforms.
Test: Tests still run on Linux hosts
Bug: 140435149
Change-Id: I298b52589ab5c6a7ec3acc4db1111596cd995d76
Diffstat (limited to 'rust/rust_test.go')
-rw-r--r-- | rust/rust_test.go | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/rust/rust_test.go b/rust/rust_test.go index c68cfe7c..f7c96dd6 100644 --- a/rust/rust_test.go +++ b/rust/rust_test.go @@ -17,6 +17,7 @@ package rust import ( "io/ioutil" "os" + "runtime" "testing" "android/soong/android" @@ -50,6 +51,11 @@ func TestMain(m *testing.M) { } func testRust(t *testing.T, bp string) *android.TestContext { + // TODO (b/140435149) + if runtime.GOOS != "linux" { + t.Skip("Only the Linux toolchain is supported for Rust") + } + t.Helper() config := android.TestArchConfig(buildDir, nil) @@ -66,6 +72,11 @@ func testRust(t *testing.T, bp string) *android.TestContext { } func testRustError(t *testing.T, pattern string, bp string) { + // TODO (b/140435149) + if runtime.GOOS != "linux" { + t.Skip("Only the Linux toolchain is supported for Rust") + } + t.Helper() config := android.TestArchConfig(buildDir, nil) |