public void Test(string inputStr, string expectedStr) { var input = JsonConvert.DeserializeObject <int[]>(inputStr); var s = new Solution(); var output = s.DeckRevealedIncreasing(input); var outputStr = JsonConvert.SerializeObject(output); outputStr.Should().Be(expectedStr); }