Add tests and fix exports diagnostics
- Add tests for the following diagnostics: GD0101, GD0102, GD0103, GD0104, GD0105, GD0106, GD0107. - Fix GD0101 not being reported any more (was filtering static classes before reporting). - Fix GD0107 not preventing `Node` members from being exported from not-`Node` types.
This commit is contained in:
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0101
|
||||
{
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0102
|
||||
{
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0103
|
||||
{
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0104
|
||||
{
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0105
|
||||
{
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0106_KO
|
||||
{
|
||||
}
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
partial class ExportDiagnostics_GD0106_OK
|
||||
{
|
||||
#pragma warning disable CS0109 // Disable warning about redundant 'new' keyword
|
||||
#if TOOLS
|
||||
/// <summary>
|
||||
/// Get the default values for all properties declared in this class.
|
||||
/// This method is used by Godot to determine the value that will be
|
||||
/// used by the inspector when resetting properties.
|
||||
/// Do not call this method.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsable(global::System.ComponentModel.EditorBrowsableState.Never)]
|
||||
internal new static global::System.Collections.Generic.Dictionary<global::Godot.StringName, global::Godot.Variant> GetGodotPropertyDefaultValues()
|
||||
{
|
||||
var values = new global::System.Collections.Generic.Dictionary<global::Godot.StringName, global::Godot.Variant>(1);
|
||||
int __MyProperty_default_value = default;
|
||||
values.Add(PropertyName.MyProperty, global::Godot.Variant.From<int>(__MyProperty_default_value));
|
||||
return values;
|
||||
}
|
||||
#endif // TOOLS
|
||||
#pragma warning restore CS0109
|
||||
}
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
partial class ExportDiagnostics_GD0107_KO
|
||||
{
|
||||
}
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
partial class ExportDiagnostics_GD0107_OK
|
||||
{
|
||||
#pragma warning disable CS0109 // Disable warning about redundant 'new' keyword
|
||||
#if TOOLS
|
||||
/// <summary>
|
||||
/// Get the default values for all properties declared in this class.
|
||||
/// This method is used by Godot to determine the value that will be
|
||||
/// used by the inspector when resetting properties.
|
||||
/// Do not call this method.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsable(global::System.ComponentModel.EditorBrowsableState.Never)]
|
||||
internal new static global::System.Collections.Generic.Dictionary<global::Godot.StringName, global::Godot.Variant> GetGodotPropertyDefaultValues()
|
||||
{
|
||||
var values = new global::System.Collections.Generic.Dictionary<global::Godot.StringName, global::Godot.Variant>(2);
|
||||
global::Godot.Node __NodeProperty_default_value = default;
|
||||
values.Add(PropertyName.NodeProperty, global::Godot.Variant.From<global::Godot.Node>(__NodeProperty_default_value));
|
||||
global::Godot.Node __NodeField_default_value = default;
|
||||
values.Add(PropertyName.NodeField, global::Godot.Variant.From<global::Godot.Node>(__NodeField_default_value));
|
||||
return values;
|
||||
}
|
||||
#endif // TOOLS
|
||||
#pragma warning restore CS0109
|
||||
}
|
||||
Reference in New Issue
Block a user