Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions src/Java.Interop.Localization/Resources.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 0 additions & 4 deletions src/Java.Interop.Localization/Resources.resx
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,6 @@ In this message, the term "constants" refers to class or interface members that
<value>Unexpected 'global::' specification. This error happens if 'global::' is specified in the Metadata.xml transform file, for example.</value>
<comment>The following are literal names and should not be translated: global::, Metadata.xml.</comment>
</data>
<data name="Generator_BG4500" xml:space="preserve">
<value>'lang-features=default-interface-methods' is not compatible with 'codegen-target=xamarinandroid'.</value>
<comment>The following are literal command line arguments and should not be translated: 'lang-features=default-interface-methods', 'codegen-target=xamarinandroid'.</comment>
</data>
<data name="Generator_BG8101" xml:space="preserve">
<value>Unexpected class child {0}.</value>
<comment>{0} - The unexpected child class.</comment>
Expand Down
1 change: 0 additions & 1 deletion src/Java.Interop.Tools.Generator/Utilities/Report.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ public LocalizedMessage (int code, string value)
public static LocalizedMessage ErrorRemoveAttrInvalidXPath => new LocalizedMessage (0x4306, Localization.Resources.Generator_BG4300);
public static LocalizedMessage ErrorMissingAttrName => new LocalizedMessage (0x4307, Localization.Resources.Generator_BG4307);
public static LocalizedMessage ErrorUnexpectedGlobal => new LocalizedMessage (0x4400, Localization.Resources.Generator_BG4400);
public static LocalizedMessage ErrorInvalidDIMArgument => new LocalizedMessage (0x4500, Localization.Resources.Generator_BG4500);

public static LocalizedMessage WarningUnexpectedChild => new LocalizedMessage (0x8101, Localization.Resources.Generator_BG8101);
public static LocalizedMessage WarningUnknownBaseType => new LocalizedMessage (0x8102, Localization.Resources.Generator_BG8102);
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/AccessModifiers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "AccessModifiers",
apiDescriptionFile: "expected/AccessModifiers/AccessModifiers.xml",
apiDescriptionFile: "expected.ji/AccessModifiers/AccessModifiers.xml",
expectedRelativePath: "AccessModifiers",
additionalSupportPaths: null);
}
Expand Down
6 changes: 3 additions & 3 deletions tests/generator-Tests/Integration-Tests/Adapters.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -13,9 +13,9 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "Adapters",
apiDescriptionFile: "expected/Adapters/Adapters.xml",
apiDescriptionFile: "expected.ji/Adapters/Adapters.xml",
expectedRelativePath: "Adapters",
additionalSupportPaths: new[]{ "expected/Adapters/SupportFiles" });
additionalSupportPaths: new[]{ "expected.ji/Adapters/SupportFiles" });
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "Android.Graphics.Color",
apiDescriptionFile: "expected/Android.Graphics.Color/Android.Graphics.Color.xml",
apiDescriptionFile: "expected.ji/Android.Graphics.Color/Android.Graphics.Color.xml",
expectedRelativePath: "Android.Graphics.Color");
}
}
Expand Down
4 changes: 2 additions & 2 deletions tests/generator-Tests/Integration-Tests/Arrays.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "Arrays",
apiDescriptionFile: "expected/Arrays/Arrays.xml",
apiDescriptionFile: "expected.ji/Arrays/Arrays.xml",
expectedRelativePath: "Arrays");
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ private byte[] ReadAllBytesIgnoringLineEndings (string path)

protected void RunAllTargets (string outputRelativePath, string apiDescriptionFile, string expectedRelativePath, string[] additionalSupportPaths = null, string enumFieldsMapFile = null, string enumMethodMapFile = null, string metadataFile = null)
{
Run (CodeGenerationTarget.XamarinAndroid, Path.Combine ("out", outputRelativePath), apiDescriptionFile, Path.Combine ("expected", expectedRelativePath), additionalSupportPaths, enumFieldsMapFile, enumMethodMapFile, metadataFile);
Run (CodeGenerationTarget.XAJavaInterop1, Path.Combine ("out.xaji", outputRelativePath), apiDescriptionFile, Path.Combine ("expected.xaji", expectedRelativePath), additionalSupportPaths, enumFieldsMapFile, enumMethodMapFile, metadataFile);
#if NET
if (TryJavaInterop1) {
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/CSharpKeywords.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "CSharpKeywords",
apiDescriptionFile: "expected/CSharpKeywords/CSharpKeywords.xml",
apiDescriptionFile: "expected.ji/CSharpKeywords/CSharpKeywords.xml",
expectedRelativePath: "CSharpKeywords");
}
}
Expand Down
4 changes: 2 additions & 2 deletions tests/generator-Tests/Integration-Tests/Constructors.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "Constructors",
apiDescriptionFile: "expected/Constructors/Constructors.xml",
apiDescriptionFile: "expected.ji/Constructors/Constructors.xml",
expectedRelativePath: "Constructors");
}
}
Expand Down
4 changes: 2 additions & 2 deletions tests/generator-Tests/Integration-Tests/Core_ClassParse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ public void GeneratedOK ()

RunAllTargets (
outputRelativePath: "Core_ClassParse",
apiDescriptionFile: "expected/Core_ClassParse/api.xml",
apiDescriptionFile: "expected.ji/Core_ClassParse/api.xml",
expectedRelativePath: "Core_ClassParse",
metadataFile: FullPath ("expected/Core_ClassParse/metadata.xml"));
metadataFile: FullPath ("expected.ji/Core_ClassParse/metadata.xml"));
}
}
}
Expand Down
6 changes: 3 additions & 3 deletions tests/generator-Tests/Integration-Tests/Core_Jar2Xml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ public void GeneratedOK ()

RunAllTargets (
outputRelativePath: "Core_Jar2Xml",
apiDescriptionFile: "expected/Core_Jar2Xml/api.xml",
apiDescriptionFile: "expected.ji/Core_Jar2Xml/api.xml",
expectedRelativePath: "Core_Jar2Xml",
enumFieldsMapFile: "expected/Core_Jar2Xml/fields.xml",
enumMethodMapFile: "expected/Core_Jar2Xml/methods.xml"
enumFieldsMapFile: "expected.ji/Core_Jar2Xml/fields.xml",
enumMethodMapFile: "expected.ji/Core_Jar2Xml/methods.xml"
);
}
}
Expand Down
26 changes: 0 additions & 26 deletions tests/generator-Tests/Integration-Tests/Enumerations.cs

This file was deleted.

4 changes: 2 additions & 2 deletions tests/generator-Tests/Integration-Tests/GenericArguments.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -13,7 +13,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "GenericArguments",
apiDescriptionFile: "expected/GenericArguments/GenericArguments.xml",
apiDescriptionFile: "expected.ji/GenericArguments/GenericArguments.xml",
expectedRelativePath: "GenericArguments",
additionalSupportPaths: null);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "InterfaceMethodsConflict",
apiDescriptionFile: "expected/InterfaceMethodsConflict/InterfaceMethodsConflict.xml",
apiDescriptionFile: "expected.ji/InterfaceMethodsConflict/InterfaceMethodsConflict.xml",
expectedRelativePath: "InterfaceMethodsConflict");
}
}
Expand Down
4 changes: 2 additions & 2 deletions tests/generator-Tests/Integration-Tests/Interfaces.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using System;
using System;
using NUnit.Framework;

namespace generatortests
Expand All @@ -13,7 +13,7 @@ public void Generated_OK ()
{
RunAllTargets (
outputRelativePath: "TestInterface",
apiDescriptionFile: "expected/TestInterface/TestInterface.xml",
apiDescriptionFile: "expected.ji/TestInterface/TestInterface.xml",
expectedRelativePath: "TestInterface");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/Java_Lang_Enum.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public void Generated_OK ()
{
RunAllTargets (
outputRelativePath: "java.lang.Enum",
apiDescriptionFile: "expected/java.lang.Enum/Java.Lang.Enum.xml",
apiDescriptionFile: "expected.ji/java.lang.Enum/Java.Lang.Enum.xml",
expectedRelativePath: "java.lang.Enum");
}
}
Expand Down
14 changes: 1 addition & 13 deletions tests/generator-Tests/Integration-Tests/Java_Lang_Object.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,9 @@ public class Java_Lang_Object : BaseGeneratorTest
[Test]
public void Generated_OK ()
{
Run (target: Xamarin.Android.Binder.CodeGenerationTarget.XamarinAndroid,
outputPath: "out/java.lang.Object",
apiDescriptionFile: "expected/java.lang.Object/java.lang.Object.xml",
expectedPath: "expected/java.lang.Object");

var javaLangObject = BuiltAssembly.GetType ("Java.Lang.Object");

Assert.IsNotNull (javaLangObject);
Assert.IsTrue (javaLangObject.IsPublic);
Assert.IsTrue (javaLangObject.FullName == "Java.Lang.Object");
Assert.IsTrue (javaLangObject.GetCustomAttributes (false).Any (x => x.GetType ().Name == "RegisterAttribute"));

Run (target: Xamarin.Android.Binder.CodeGenerationTarget.JavaInterop1,
outputPath: "out.ji/java.lang.Object",
apiDescriptionFile: "expected/java.lang.Object/java.lang.Object.xml",
apiDescriptionFile: "expected.ji/java.lang.Object/java.lang.Object.xml",
expectedPath: "expected.ji/java.lang.Object");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/Java_Util_List.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "java.util.List",
apiDescriptionFile: "expected/java.util.List/java.util.List.xml",
apiDescriptionFile: "expected.ji/java.util.List/java.util.List.xml",
expectedRelativePath: "java.util.List");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/NestedTypes.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "NestedTypes",
apiDescriptionFile: "expected/NestedTypes/NestedTypes.xml",
apiDescriptionFile: "expected.ji/NestedTypes/NestedTypes.xml",
expectedRelativePath: "NestedTypes");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/NonStaticFields.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "NonStaticFields",
apiDescriptionFile: "expected/NonStaticFields/NonStaticField.xml",
apiDescriptionFile: "expected.ji/NonStaticFields/NonStaticField.xml",
expectedRelativePath: "NonStaticFields");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/NormalMethods.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "NormalMethods",
apiDescriptionFile: "expected/NormalMethods/NormalMethods.xml",
apiDescriptionFile: "expected.ji/NormalMethods/NormalMethods.xml",
expectedRelativePath: "NormalMethods");
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "NormalProperties",
apiDescriptionFile: "expected/NormalProperties/NormalProperties.xml",
apiDescriptionFile: "expected.ji/NormalProperties/NormalProperties.xml",
expectedRelativePath: "NormalProperties");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/PamareterXPath.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "ParameterXPath",
apiDescriptionFile: "expected/ParameterXPath/ParameterXPath.xml",
apiDescriptionFile: "expected.ji/ParameterXPath/ParameterXPath.xml",
expectedRelativePath: "ParameterXPath");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/StaticFields.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "StaticFields",
apiDescriptionFile: "expected/StaticFields/StaticField.xml",
apiDescriptionFile: "expected.ji/StaticFields/StaticField.xml",
expectedRelativePath: "StaticFields");
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/generator-Tests/Integration-Tests/StaticMethods.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "StaticMethods",
apiDescriptionFile: "expected/StaticMethods/StaticMethod.xml",
apiDescriptionFile: "expected.ji/StaticMethods/StaticMethod.xml",
expectedRelativePath: "StaticMethods");
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "StaticProperties",
apiDescriptionFile: "expected/StaticProperties/StaticProperties.xml",
apiDescriptionFile: "expected.ji/StaticProperties/StaticProperties.xml",
expectedRelativePath: "StaticProperties");
}
}
Expand Down
4 changes: 2 additions & 2 deletions tests/generator-Tests/Integration-Tests/Streams.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ public void GeneratedOK ()
{
RunAllTargets (
outputRelativePath: "Streams",
apiDescriptionFile: "expected/Streams/Streams.xml",
apiDescriptionFile: "expected.ji/Streams/Streams.xml",
expectedRelativePath: "Streams",
additionalSupportPaths: new[]{ "expected/Streams/SupportFiles" });
additionalSupportPaths: new[]{ "expected.ji/Streams/SupportFiles" });
}
}
}
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

Loading