virtualx-engine/modules/mono/editor/Godot.NET.Sdk/Godot.SourceGenerators.Tests/Constants.cs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
746 B
C#
Raw Normal View History

using System.IO;
using System.Reflection;
namespace Godot.SourceGenerators.Tests;
public static class Constants
{
public static Assembly GodotSharpAssembly => typeof(GodotObject).Assembly;
public static string ExecutingAssemblyPath { get; }
public static string SourceFolderPath { get; }
public static string GeneratedSourceFolderPath { get; }
static Constants()
{
ExecutingAssemblyPath = Path.GetFullPath(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location!)!);
var testDataPath = Path.Combine(ExecutingAssemblyPath, "TestData");
SourceFolderPath = Path.Combine(testDataPath, "Sources");
GeneratedSourceFolderPath = Path.Combine(testDataPath, "GeneratedSources");
}
}