Add Day10 implementation with puzzle-solving logic and tests

This commit is contained in:
Sebastian Lindemeier
2025-12-11 06:02:07 +01:00
parent 82772fd4e0
commit 6621a36021
3 changed files with 150 additions and 1 deletions
+47
View File
@@ -0,0 +1,47 @@
using AdvenOfCode.Contracts;
namespace AoC_2025.Tests;
public class Day10Test
{
private IPuzzleSolver<long> _sut;
private static readonly string rootPath = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments);
private readonly string TestInputPath = @$"{rootPath}\AoC-PuzzleInputs\2025\Test\day10.txt";
private readonly string ProdInputPath = @$"{rootPath}\AoC-PuzzleInputs\2025\Prod\day10.txt";
public Day10Test()
{
_sut = new Day10();
}
[Fact]
public void Part01_Test_equals_7()
{
var actual = _sut.SolvePart1(TestInputPath);
Assert.Equal(7, actual);
}
[Fact]
public void Part01_Prod_equals_500()
{
var actual = _sut.SolvePart1(ProdInputPath);
Assert.Equal(500, actual);
}
[Fact]
public void Part02_Test_equals_24()
{
var actual = _sut.SolvePart2(TestInputPath);
Assert.Equal(24, actual);
}
[Fact]
public void Part02_Prod_equals_1568849600()
{
var actual = _sut.SolvePart2(ProdInputPath);
Assert.Equal(1568849600, actual);
}
}