public void BannedSwapping_NotUsed() { var sut = new BannedPieceType("s"); var sequence = new LinkedList <ISquarePiece>(); sequence.AddLast(CreatePiece(PieceTypes.Rainbow)); sequence.AddLast(CreatePiece(PieceTypes.ThreePoints)); sequence.AddLast(CreatePiece(PieceTypes.FourPoints)); sut.SequenceCompleted(sequence.ToArray()); Assert.IsFalse(sut.ViolatedRestriction()); }
public void BannedRainbow_Used() { var sut = new BannedPieceType("r"); var sequence = new LinkedList <ISquarePiece>(); sequence.AddLast(CreatePiece(PieceTypes.Normal)); sequence.AddLast(CreatePiece(PieceTypes.Rainbow)); sequence.AddLast(CreatePiece(PieceTypes.Normal)); sut.SequenceCompleted(sequence.ToArray()); Assert.IsTrue(sut.ViolatedRestriction()); }