Skip to content

Commit 8d7060d

Browse files
jonpryoratsushieno
authored andcommitted
[Xamarin.Android.Tools.Bytecode-Tests] Update for API-24 docs (#142)
The `ParameterFixupTests.XmlDeclaration_FixedUpFromDocumentation()` and `ParameterFixupTests.XmlDeclaration_FixedUpFromApiXmlDocumentation()` tests read a `java.util.Collection.class` file that contains no parameter name information, and uses XML and/or "JavaDoc" HTML documentation to ascertain the correct parameter names. For better or worse, parameter names are *not* part of any Java ABI, and thus can change over time. Which is what happened here: these tests were originally written against the Android documentation for API-18. Since then, the docs for API-24 have *changed the parameter names* for the `Collection.add(E)` method, changing the parameter name from `object` to `e`. Update the expected paramater names when reading docs from `$ANDROID_SDK_PATH` so that the API-24 names are expected.
1 parent 7dfeba2 commit 8d7060d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Xamarin.Android.Tools.Bytecode/Tests/ParameterFixupApiXmlDocs.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<package name="java.util">
44
<class name="Collection">
55
<method name="add">
6-
<parameter name="object" type="E" />
6+
<parameter name="e" type="E" />
77
</method>
88
</class>
99
</package>

src/Xamarin.Android.Tools.Bytecode/Tests/ParameterFixupFromDocs.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
synthetic="false"
3939
jni-signature="(Ljava/lang/Object;)Z">
4040
<parameter
41-
name="object"
41+
name="e"
4242
type="E"
4343
jni-type="TE;" />
4444
</method>

0 commit comments

Comments
 (0)