summaryrefslogtreecommitdiff
path: root/scripts/manifest_fixer_test.py
diff options
context:
space:
mode:
author Colin Cross <ccross@android.com> 2018-10-01 15:15:51 -0700
committer Colin Cross <ccross@android.com> 2018-10-02 12:39:38 -0700
commit4b176069c3efbb6e8a9793fc7c689e4e1f89075e (patch)
tree8f1aad55b2e55126122c0fe56d5a4dab0c54ebee /scripts/manifest_fixer_test.py
parent16d387c970421be7060d74ac1957f6047478afaf (diff)
Don't set targetSdkVersion to '1' for libraries
Setting targetSdkVersion to '1' causes ManifestMerger to add implicit permissions when merging to a higher targetSdkVersion. It should really be unset, but ManifestMerger treats unset targetSdkVersion as 'Q' if minSdkVersion is 'Q' (but not if minSdkVersion is '28'). Set it to something low so that it will be overriden by the main manifest, but high enough that it doesn't cause implicit permissions grants. Bug: 115415671 Bug: 117122200 Test: m checkbuild Change-Id: I1d2d031a21314f6b55d8ea1cc7c4c8e3ecae7f06
Diffstat (limited to 'scripts/manifest_fixer_test.py')
-rwxr-xr-xscripts/manifest_fixer_test.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/manifest_fixer_test.py b/scripts/manifest_fixer_test.py
index 66a2317f5..d1d401a77 100755
--- a/scripts/manifest_fixer_test.py
+++ b/scripts/manifest_fixer_test.py
@@ -173,7 +173,7 @@ class RaiseMinSdkVersionTest(unittest.TestCase):
"""Tests inserting targetSdkVersion when minSdkVersion exists."""
manifest_input = self.manifest_tmpl % self.uses_sdk(min='27')
- expected = self.manifest_tmpl % self.uses_sdk(min='28', target='1')
+ expected = self.manifest_tmpl % self.uses_sdk(min='28', target='15')
output = self.raise_min_sdk_version_test(manifest_input, '28', '29', True)
self.assertEqual(output, expected)
@@ -189,7 +189,7 @@ class RaiseMinSdkVersionTest(unittest.TestCase):
"""Tests inserting targetSdkVersion when minSdkVersion does not exist."""
manifest_input = self.manifest_tmpl % ''
- expected = self.manifest_tmpl % self.uses_sdk(min='28', target='1')
+ expected = self.manifest_tmpl % self.uses_sdk(min='28', target='15')
output = self.raise_min_sdk_version_test(manifest_input, '28', '29', True)
self.assertEqual(output, expected)