public void TestSwapCharacter() { Puzzle21 toTest = new Puzzle21(); string instruction = "swap letter 1 with letter 5"; string output = toTest.ApplySwapInstruction(instruction.Split(' '), new char[] { '1', '2', '3', '4', '5' }); Assert.AreEqual("52341", output); }
public void TestSwapPosition() { Puzzle21 toTest = new Puzzle21(); string instruction = "swap position 0 with position 4"; string output = toTest.ApplySwapInstruction(instruction.Split(' '), new char[] { '1', '2', '3', '4', '5' }); Assert.AreEqual("52341", output); }