public void CanCountUniqueCharsExcludingSpaces(string value, int expected) { var day6 = new Day6(); var result = day6.CountUniqueCharsExcludingSpaces(value); Assert.Equal(expected, result); }
public void CanSolvePart2(string[] input, int expected) { var day6 = new Day6(); var result = day6.SolvePart2(input); Assert.Equal(expected, result); }
public void TestPartB() { string[] inputData = new string[] { "abc", "", "a", "b", "c", "", "ab", "ac", "", "a", "a", "a", "a", "", "b" }; int expectedOutput = 6; var data = new StringData(inputData); Day6 day = new Day6(data); var actualOutut = day.Puzzle2Solution(); Assert.AreEqual(expectedOutput, actualOutut); }
public void TotalBrightness(string input, int expectedOn) { var day6 = new Day6(); var actual = day6.TotalBrightness(input); Assert.Equal(expectedOn, actual); }
public void TotalBrightnessActual() { var input = LoadFromResource.Load("AdventOfCode.Tests.TestData.Day6.txt"); const int expected = 14687245; var day6 = new Day6(); var actual = day6.TotalBrightness(input); Assert.Equal(expected, actual); }
public void TotalTurnedOnActual() { var input = LoadFromResource.Load("AdventOfCode.Tests.TestData.Day6.txt"); const int expected = 543903; var day6 = new Day6(); var actual = day6.TotalTurnedOn(input); Assert.Equal(expected, actual); }
public void TestDay6Part2(string[] input, string answer) { Day6. Part2(input). ShouldBeEquivalentTo(answer); }
public void Part2RealPuzzle() { var result = Day6.SolvePart2(GetPuzzleInput()); Assert.Equal(1086, result); }
public void Part1RealPuzzle() { var result = Day6.SolvePart1(GetPuzzleInput()); Assert.Equal(5042, result); }