summaryrefslogtreecommitdiff
path: root/java/java_test.go
diff options
context:
space:
mode:
author Liz Kammer <eakammer@google.com> 2020-07-30 15:07:22 -0700
committer David Dietrich <drdietri@google.com> 2020-10-15 06:12:21 +0000
commit10ed76345143a3d293066149d2bde4dab0309c52 (patch)
tree1722b80bd0079d4cf5840ef0247be55bd0425d91 /java/java_test.go
parent725e81982739a2082df47ea9637c974fc9425ec0 (diff)
Default to not creating stubs for droiddoc
This will allow us to remove `create_stubs: false` throughout the codebase easily, then remove the functionslity to create stubs from droiddoc. Test: m docs Test: m checkapi Test: m updateapi Bug: 144248501 Bug: 143136634 Change-Id: Ib95f68bc064fbe1475e4b25433bee6292bc005dc Merged-In: I1ab8091bf696d94da3547cf5248853df489bdee6
Diffstat (limited to 'java/java_test.go')
-rw-r--r--java/java_test.go9
1 files changed, 7 insertions, 2 deletions
diff --git a/java/java_test.go b/java/java_test.go
index 266cada35..fc8dd7ecb 100644
--- a/java/java_test.go
+++ b/java/java_test.go
@@ -1001,8 +1001,13 @@ func TestDroiddoc(t *testing.T) {
"bar-doc/a.java": nil,
"bar-doc/b.java": nil,
})
+ barDocModule := ctx.ModuleForTests("bar-doc", "android_common")
+ barDoc := barDocModule.Rule("javadoc")
+ notExpected := " -stubs "
+ if strings.Contains(barDoc.RuleParams.Command, notExpected) {
+ t.Errorf("bar-doc command contains flag %q to create stubs, but should not", notExpected)
+ }
- barDoc := ctx.ModuleForTests("bar-doc", "android_common").Rule("javadoc")
var javaSrcs []string
for _, i := range barDoc.Inputs {
javaSrcs = append(javaSrcs, i.Base())
@@ -1011,7 +1016,7 @@ func TestDroiddoc(t *testing.T) {
t.Errorf("inputs of bar-doc must be []string{\"a.java\"}, but was %#v.", javaSrcs)
}
- aidl := ctx.ModuleForTests("bar-doc", "android_common").Rule("aidl")
+ aidl := barDocModule.Rule("aidl")
if g, w := barDoc.Implicits.Strings(), aidl.Output.String(); !inList(w, g) {
t.Errorf("implicits of bar-doc must contain %q, but was %q.", w, g)
}