示例#1
0
        public void TestSuccessfulMove(int xCoordinate, int yCoordinate, Orientation orientation)
        {
            _positionTracker.SetPosition(xCoordinate, yCoordinate);
            _positionTracker.SetOrientation(orientation);
            var outcome = _movementProcessor.Move();

            outcome.Result.ShouldBe(OutcomeStatus.Success);
        }
示例#2
0
 public void TestTrackPosition(int xPos, int yPos)
 {
     positionTracker.SetPosition(xPos, yPos);
     (int x, int y) = positionTracker.GetPosition();
     x.ShouldBe(xPos);
     y.ShouldBe(yPos);
 }
示例#3
0
        public void TestPositionReport(int xCoordinate, int yCoordinate, Orientation orientation)
        {
            positionTracker.SetPosition(xCoordinate, yCoordinate);
            positionTracker.SetOrientation(orientation);
            var report = positionReporter.Report();

            report.ToString().ShouldBe($"{xCoordinate},{yCoordinate},{orientation}");
        }