You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The recent `generator` refactor (6bbb00a) caused there to be
differences in how whitespace is generated in bindings.
In order to minimize distractions in an already hard to review PR,
the test infrastructure was changed to ignore whitespace differences.
This made it possible to ensure there were no non-whitespace changes
caused by the refactor.
Clean up the generated whitespace to be closer to the original.
Copy file name to clipboardExpand all lines: tests/generator-Tests/Unit-Tests/CodeGeneratorExpectedResults/JavaInterop1/ObsoleteInterfaceAlternativeClass.txt
throw new InvalidCastException (string.Format ("Unable to convert instance of type '{0}' to type '{1}'.", JNIEnv.GetClassNameFromInstance (handle), "com.xamarin.android.Parent"));
protected MyClass (IntPtr javaReference, JniHandleOwnership transfer) : base (javaReference, transfer)
11
+
{
12
+
}
13
13
14
14
// Metadata.xml XPath constructor reference: path="/api/package[@name='java.code']/class[@name='MyClass']/constructor[@name='MyClass' and count(parameter)=0]"
15
15
[Register (".ctor", "()V", "")]
16
-
unsafe MyClass ()
17
-
: base (IntPtr.Zero, JniHandleOwnership.DoNotTransfer)
16
+
unsafe MyClass () : base (IntPtr.Zero, JniHandleOwnership.DoNotTransfer)
18
17
{
19
18
const string __id = "()V";
20
19
@@ -31,8 +30,7 @@ public partial class MyClass {
31
30
32
31
// Metadata.xml XPath constructor reference: path="/api/package[@name='java.code']/class[@name='MyClass']/constructor[@name='MyClass' and count(parameter)=1 and parameter[1][@type='java.lang.String']]"
33
32
[Register (".ctor", "(Ljava/lang/String;)V", "")]
34
-
unsafe MyClass (string p0)
35
-
: base (IntPtr.Zero, JniHandleOwnership.DoNotTransfer)
33
+
unsafe MyClass (string p0) : base (IntPtr.Zero, JniHandleOwnership.DoNotTransfer)
36
34
{
37
35
const string __id = "(Ljava/lang/String;)V";
38
36
@@ -224,9 +222,12 @@ public partial class MyClass {
224
222
225
223
public abstract int AbstractCount {
226
224
// Metadata.xml XPath method reference: path="/api/package[@name='java.code']/class[@name='MyClass']/method[@name='get_AbstractCount' and count(parameter)=0]"
// Metadata.xml XPath method reference: path="/api/package[@name='java.code']/class[@name='MyClass']/method[@name='set_AbstractCount' and count(parameter)=1 and parameter[1][@type='int']]"
Copy file name to clipboardExpand all lines: tests/generator-Tests/Unit-Tests/CodeGeneratorExpectedResults/JavaInterop1/WriteDefaultInterfaceMethodInvoker.txt
throw new InvalidCastException (string.Format ("Unable to convert instance of type '{0}' to type '{1}'.", JNIEnv.GetClassNameFromInstance (handle), "java.code.IMyInterface"));
// Metadata.xml XPath method reference: path="/api/package[@name='java.code']/interface[@name='IMyInterface']/method[@name='set_Count' and count(parameter)=1 and parameter[1][@type='int']]"
// Metadata.xml XPath method reference: path="/api/package[@name='java.code']/interface[@name='IMyInterface']/method[@name='set_Key' and count(parameter)=1 and parameter[1][@type='java.lang.String']]"
// Metadata.xml XPath method reference: path="/api/package[@name='java.code']/interface[@name='IMyInterface']/method[@name='set_AbstractCount' and count(parameter)=1 and parameter[1][@type='int']]"
// Metadata.xml XPath method reference: path="/api/package[@name='java.code']/interface[@name='IMyInterface']/method[@name='GetCountForKey' and count(parameter)=1 and parameter[1][@type='java.lang.String']]"
throw new InvalidCastException (string.Format ("Unable to convert instance of type '{0}' to type '{1}'.", JNIEnv.GetClassNameFromInstance (handle), "java.code.IMyInterface"));
0 commit comments