public void GetCombinationsWithLengthTest() { var test = new[] { 1, 2, 3 }; var result = Combinator.GetCombinationsWithLength(test.ToList(), 2).ToArray(); result.Should().NotBeNull(); result.Length.Should().Be(2); result[0].Should().BeEquivalentTo(new List <int>(new[] { 1, 2 })); result[1].Should().BeEquivalentTo(new List <int>(new[] { 2, 3 })); }