diff options
| author | 2021-06-01 14:05:09 -0700 | |
|---|---|---|
| committer | 2021-06-02 12:59:21 -0700 | |
| commit | 3dd662509d02914a09f9954b37eaa7dd164a3523 (patch) | |
| tree | e89337bae62f6696a1542591cbb70f77896195d8 /java | |
| parent | 8e590ea8540feaed5ab6768f0cf514f73bc9ac63 (diff) | |
Make the default java_sdk_library dist_group "unknown"
Change the default dist_group from "android" to "unknown" to prevent
accidentally including java_sdk_library stubs that do not set
dist_group or owner in the public SDK.
Bug: 186723288
Test: TestJavaSdkLibraryDist
Change-Id: I9aae2a16254ac1a8d444acfa63bc571d1ef4b045
Diffstat (limited to 'java')
| -rw-r--r-- | java/sdk_library.go | 5 | ||||
| -rw-r--r-- | java/sdk_library_test.go | 4 |
2 files changed, 4 insertions, 5 deletions
diff --git a/java/sdk_library.go b/java/sdk_library.go index ecf2b1a03..1936bf5fd 100644 --- a/java/sdk_library.go +++ b/java/sdk_library.go @@ -458,7 +458,7 @@ type sdkLibraryProperties struct { Dist_stem *string // The subdirectory for the artifacts that are copied to the dist directory. If not specified - // then defaults to "android". Should be set to "android" for anything that should be published + // then defaults to "unknown". Should be set to "android" for anything that should be published // in the public Android SDK. Dist_group *string @@ -1240,8 +1240,7 @@ func (module *SdkLibrary) distGroup() string { if owner := module.ModuleBase.Owner(); owner != "" { return owner } - // TODO(b/186723288): Make this "unknown". - return "android" + return "unknown" } func (module *SdkLibrary) latestApiFilegroupName(apiScope *apiScope) string { diff --git a/java/sdk_library_test.go b/java/sdk_library_test.go index 0fe6e72ef..f0f3a197f 100644 --- a/java/sdk_library_test.go +++ b/java/sdk_library_test.go @@ -888,7 +888,7 @@ func TestJavaSdkLibraryDist(t *testing.T) { testCases := []testCase{ { module: "sdklib_no_owner", - distDir: "apistubs/android/public", + distDir: "apistubs/unknown/public", distStem: "sdklib_no_owner.jar", }, { @@ -903,7 +903,7 @@ func TestJavaSdkLibraryDist(t *testing.T) { }, { module: "sdklib_stem_foo", - distDir: "apistubs/android/public", + distDir: "apistubs/unknown/public", distStem: "foo.jar", }, { |