예제 #1
0
            protected override void Given()
            {
                const int x = 5;
                const int y = 5;

                var positionOne =
                    new PositionBuilder()
                    .WithX(x)
                    .WithY(y)
                    .Build();

                _positionTwo =
                    new PositionBuilder()
                    .WithX(x + 2)
                    .WithY(y + 2)
                    .Build();

                var landingPlatform =
                    new LandingPlatformMockBuilder()
                    .WithIsPositionInsideOfPlatformMocked(IsPositionInsideOfThePlatform)
                    .WithIsAllowedPositionMocked(IsAllowedPosition)
                    .Build();

                _sut =
                    new LandingAreaBuilder()
                    .WithLandingPlatform(landingPlatform)
                    .Build();

                _sut.CheckPosition(positionOne);

                _expectedResult    = LandingAnswer;
                _expectedPositions = StoredPositions;
            }
예제 #2
0
 protected override void When()
 {
     _result = _sut.CheckPosition(_position);
 }