Retry: Adds support for 'ignored-on-host'
Adds a filter mechanism that can exclude property values from being
included in the common value extraction. That is needed to prevent the
snapshot mechanism from generating invalid output for properties that
are ignored on host (and have their values cleared) and which are not
tagged with `android:"arch_variant"`.
Changes:
* Updates the documentation of SdkMemberType to explain what effect
the 'ignored-on-host' tag has.
* Adds some tests for this new mechanism.
Bug: 155628860
Test: m nothing
Merged-In: Ibafdb6e921ba5abe505bd8a91ca5a1d9c9b5d0cb
Change-Id: Ibafdb6e921ba5abe505bd8a91ca5a1d9c9b5d0cb
(cherry picked from commit c459f89fb46e163eb57f1fc41e4a79383785db32)
diff --git a/sdk/sdk_test.go b/sdk/sdk_test.go
index 898ecea..ae1a492 100644
--- a/sdk/sdk_test.go
+++ b/sdk/sdk_test.go
@@ -289,9 +289,12 @@
}
extractor := newCommonValueExtractor(common)
- extractor.extractCommonProperties(common, structs)
h := TestHelper{t}
+
+ err := extractor.extractCommonProperties(common, structs)
+ h.AssertDeepEquals("unexpected error", nil, err)
+
h.AssertDeepEquals("common properties not correct",
&testPropertiesStruct{
name: "common",