示例#1
0
        public void RemoveCupsFromCircleCorrectly()
        {
            var sut = new CupGame(SAMPLE_DATA);

            sut.RemoveThreeCupsAfterCurrentCup();
            Assert.Collection(sut.GetCupsInOrder(),
                              c1 => Assert.Equal(3, c1),
                              c5 => Assert.Equal(5, c5));
        }
示例#2
0
        public void RemoveCupsFromCircleCorrectly_WhenUsingSampleData()
        {
            var sut = new CupGame(SAMPLE_DATA_2);

            sut.RemoveThreeCupsAfterCurrentCup();

            Assert.Collection(sut.GetCupsInOrder(),
                              c1 => Assert.Equal(3, c1),
                              c2 => Assert.Equal(2, c2),
                              c3 => Assert.Equal(5, c3),
                              c4 => Assert.Equal(4, c4),
                              c5 => Assert.Equal(6, c5),
                              c6 => Assert.Equal(7, c6));
        }
示例#3
0
        public void MoveRemovedCupsToNewPositionCorrectly()
        {
            var sut = new CupGame(SAMPLE_DATA);

            sut.RemoveThreeCupsAfterCurrentCup();
            sut.SelectDestinationCup();

            sut.MoveSelectedCupsAfterDestinationCup();
            Assert.Collection(sut.GetCupsInOrder(),
                              c1 => Assert.Equal(3, c1),
                              c2 => Assert.Equal(5, c2),
                              c3 => Assert.Equal(2, c3),
                              c4 => Assert.Equal(4, c4),
                              c5 => Assert.Equal(1, c5));
        }