diff options
author | 2023-09-22 03:58:59 +0000 | |
---|---|---|
committer | 2023-09-22 22:05:54 +0000 | |
commit | 41326c1f410bafb909a56f1cf7ca8748ce06cab3 (patch) | |
tree | 0d630e655cf5311ccc525173d4d56fc75c8cee42 /rust/image_test.go | |
parent | df0ed707a5bdbe0e3d20afe9f81acb09e2e887be (diff) |
Revert "support sandboxed rust rules"
Revert submission 2629131-sandbox-rust-inputs
Reason for revert: Fail on android build.
Reverted changes: /q/submissionid:2629131-sandbox-rust-inputs
Change-Id: Ifd9aa46e80a12d8f4ffa0a2daa74b96727cbb7e6
Diffstat (limited to 'rust/image_test.go')
-rw-r--r-- | rust/image_test.go | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/rust/image_test.go b/rust/image_test.go index 813c5bcdd..fb4d9c170 100644 --- a/rust/image_test.go +++ b/rust/image_test.go @@ -59,36 +59,36 @@ func TestImageVndkCfgFlag(t *testing.T) { vendor := ctx.ModuleForTests("libfoo", "android_vendor.29_arm64_armv8-a_static").Rule("rustc") - if !strings.Contains(vendor.RuleParams.Command, "--cfg 'android_vndk'") { - t.Errorf("missing \"--cfg 'android_vndk'\" for libfoo vendor variant, rustcFlags: %#v", vendor.RuleParams.Command) + if !strings.Contains(vendor.Args["rustcFlags"], "--cfg 'android_vndk'") { + t.Errorf("missing \"--cfg 'android_vndk'\" for libfoo vendor variant, rustcFlags: %#v", vendor.Args["rustcFlags"]) } - if !strings.Contains(vendor.RuleParams.Command, "--cfg 'android_vendor'") { - t.Errorf("missing \"--cfg 'android_vendor'\" for libfoo vendor variant, rustcFlags: %#v", vendor.RuleParams.Command) + if !strings.Contains(vendor.Args["rustcFlags"], "--cfg 'android_vendor'") { + t.Errorf("missing \"--cfg 'android_vendor'\" for libfoo vendor variant, rustcFlags: %#v", vendor.Args["rustcFlags"]) } - if strings.Contains(vendor.RuleParams.Command, "--cfg 'android_product'") { - t.Errorf("unexpected \"--cfg 'android_product'\" for libfoo vendor variant, rustcFlags: %#v", vendor.RuleParams.Command) + if strings.Contains(vendor.Args["rustcFlags"], "--cfg 'android_product'") { + t.Errorf("unexpected \"--cfg 'android_product'\" for libfoo vendor variant, rustcFlags: %#v", vendor.Args["rustcFlags"]) } product := ctx.ModuleForTests("libfoo", "android_product.29_arm64_armv8-a_static").Rule("rustc") - if !strings.Contains(product.RuleParams.Command, "--cfg 'android_vndk'") { - t.Errorf("missing \"--cfg 'android_vndk'\" for libfoo product variant, rustcFlags: %#v", product.RuleParams.Command) + if !strings.Contains(product.Args["rustcFlags"], "--cfg 'android_vndk'") { + t.Errorf("missing \"--cfg 'android_vndk'\" for libfoo product variant, rustcFlags: %#v", product.Args["rustcFlags"]) } - if strings.Contains(product.RuleParams.Command, "--cfg 'android_vendor'") { - t.Errorf("unexpected \"--cfg 'android_vendor'\" for libfoo product variant, rustcFlags: %#v", product.RuleParams.Command) + if strings.Contains(product.Args["rustcFlags"], "--cfg 'android_vendor'") { + t.Errorf("unexpected \"--cfg 'android_vendor'\" for libfoo product variant, rustcFlags: %#v", product.Args["rustcFlags"]) } - if !strings.Contains(product.RuleParams.Command, "--cfg 'android_product'") { - t.Errorf("missing \"--cfg 'android_product'\" for libfoo product variant, rustcFlags: %#v", product.RuleParams.Command) + if !strings.Contains(product.Args["rustcFlags"], "--cfg 'android_product'") { + t.Errorf("missing \"--cfg 'android_product'\" for libfoo product variant, rustcFlags: %#v", product.Args["rustcFlags"]) } system := ctx.ModuleForTests("libfoo", "android_arm64_armv8-a_static").Rule("rustc") - if strings.Contains(system.RuleParams.Command, "--cfg 'android_vndk'") { - t.Errorf("unexpected \"--cfg 'android_vndk'\" for libfoo system variant, rustcFlags: %#v", system.RuleParams.Command) + if strings.Contains(system.Args["rustcFlags"], "--cfg 'android_vndk'") { + t.Errorf("unexpected \"--cfg 'android_vndk'\" for libfoo system variant, rustcFlags: %#v", system.Args["rustcFlags"]) } - if strings.Contains(system.RuleParams.Command, "--cfg 'android_vendor'") { - t.Errorf("unexpected \"--cfg 'android_vendor'\" for libfoo system variant, rustcFlags: %#v", system.RuleParams.Command) + if strings.Contains(system.Args["rustcFlags"], "--cfg 'android_vendor'") { + t.Errorf("unexpected \"--cfg 'android_vendor'\" for libfoo system variant, rustcFlags: %#v", system.Args["rustcFlags"]) } - if strings.Contains(system.RuleParams.Command, "--cfg 'android_product'") { - t.Errorf("unexpected \"--cfg 'android_product'\" for libfoo system variant, rustcFlags: %#v", product.RuleParams.Command) + if strings.Contains(system.Args["rustcFlags"], "--cfg 'android_product'") { + t.Errorf("unexpected \"--cfg 'android_product'\" for libfoo system variant, rustcFlags: %#v", product.Args["rustcFlags"]) } } |