chore(*): Add editorconfig

This commit is contained in:
Josh Creek
2023-12-04 11:54:27 +00:00
parent 65622c6100
commit c5b096dbea
2 changed files with 325 additions and 44 deletions
+42 -41
View File
@@ -1,45 +1,46 @@
using System.Reflection;
namespace AOC.Tests.YX;
namespace AOC.Tests.YX
[TestFixture]
[Parallelizable(ParallelScope.All)]
public class DayX
{
[TestFixture, Parallelizable(ParallelScope.All)]
public class DayX
[SetUp]
public void Setup()
{
protected string GetThisClassName() { return this.GetType().Name; }
private string[] realData;
[SetUp]
public void Setup()
{
realData = File.ReadAllLines(Path.Combine(TestContext.CurrentContext.TestDirectory, "YX", "Data", $"{GetThisClassName()}.dat"));
}
[TestCase("blah", 0)]
[TestCase(null, 232)] // The actual answer
public void Part1(string input, int? expected)
{
string[] lines = input != null ? new[] { input } : realData;
//if (expected != null)
//{
// Assert.That(result, Is.EqualTo(expected.Value));
//}
//Console.WriteLine($"Part 1: {result}");
}
[TestCase("blah", 1)]
[TestCase(null, 1783)] // The actual answer
public void Part2(string input, int? expected)
{
//string[] lines = input != null ? new[] { input } : realData;
//if (expected != null)
//{
// Assert.That(result, Is.EqualTo(expected.Value));
//}
//Console.WriteLine($"Part 2: {result}");
}
realData = File.ReadAllLines(Path.Combine(TestContext.CurrentContext.TestDirectory, "YX", "Data",
$"{GetThisClassName()}.dat"));
}
}
protected string GetThisClassName() { return GetType().Name; }
private string[] realData;
[TestCase("blah", 0)]
[TestCase(null, 232)] // The actual answer
public void Part1(string input, int? expected)
{
string[] lines = input != null ? new[] { input } : realData;
// string[] lines = input != null ? input.Split("\n") : realData;
//if (expected != null)
//{
// Assert.That(result, Is.EqualTo(expected.Value));
//}
//Console.WriteLine($"Part 1: {result}");
}
[TestCase("blah", 1)]
[TestCase(null, 1783)] // The actual answer
public void Part2(string input, int? expected)
{
//string[] lines = input != null ? new[] { input } : realData;
// string[] lines = input != null ? input.Split("\n") : realData;
//if (expected != null)
//{
// Assert.That(result, Is.EqualTo(expected.Value));
//}
//Console.WriteLine($"Part 2: {result}");
}
}