public void turn_on_first_line_of_lights_then_turn_off_middle_200()
 {
     var instruction1 = AOC_2015_Day06_Answer.ParseInstruction("toggle 0,0 through 999,0");
     var instruction2 = AOC_2015_Day06_Answer.ParseInstruction("toggle 400,0 through 599,0");
     var answer = AOC_2015_Day06_Answer.CalculateLitLights(new[] { instruction1, instruction2 });
     answer.Should().Be(800);
 }
 public void increase_brightness_by_one()
 {
     var input = "turn on 0,0 through 0,0";
     var parsedInput = AOC_2015_Day06_Answer.ParseInstruction(input);
     var answer = AOC_2015_Day06_Answer.CalculateLitLights2(new[] { parsedInput });
     answer.Should().Be(1);
 }
 public void turn_on_first_line_of_lights()
 {
     var input = "toggle 0,0 through 999,0";
     var parsedInput = AOC_2015_Day06_Answer.ParseInstruction(input);
     var answer = AOC_2015_Day06_Answer.CalculateLitLights(new[] { parsedInput });
     answer.Should().Be(1000);
 }
 public void AOC_2015_Day06b()
 {
     var input = File.ReadAllText(".//Content//Day06.txt")
                     .Split(Environment.NewLine)
                     .Select(x => AOC_2015_Day06_Answer.ParseInstruction(x))
                     .ToArray();
     var answer = AOC_2015_Day06_Answer.CalculateLitLights2(input);
     answer.Should().Be(14110788);
 }
 public void parse_instruction_On()
 {
     var input = "turn on 0,0 through 999,999";
     var answer = AOC_2015_Day06_Answer.ParseInstruction(input);
     answer.Should().BeEquivalentTo(
             new Instruction
             {
                 Type = InstructionType.On,
                 Start = new Coordinate
                 {
                     X = 0,
                     Y = 0
                 },
                 End = new Coordinate
                 {
                     X = 999,
                     Y = 999
                 }
             }
         ); ;
 }
 public void parse_instruction_Off()
 {
     var input = "turn off 499,499 through 500,500";
     var answer = AOC_2015_Day06_Answer.ParseInstruction(input);
     answer.Should().BeEquivalentTo(
             new Instruction
             {
                 Type = InstructionType.Off,
                 Start = new Coordinate
                 {
                     X = 499,
                     Y = 499
                 },
                 End = new Coordinate
                 {
                     X = 500,
                     Y = 500
                 }
             }
         ); ;
 }