コード例 #1
0
 public CommandExecutorTest()
 {
     _mockMovementProcessor = SubstituteFor <IMovementProcessor>();
     _mockPositionReporter  = SubstituteFor <IPositionReporter>();
     BuildServices();
     _executor = serviceProvider.GetService <ICommandExecutor>();
 }
コード例 #2
0
        public void SetUp()
        {
            if (!partBehaviour.PartInstance.TryGetComponent <MovementInputBehaviour>(out var movementInputBehaviour))
            {
                return;
            }

            if (!partBehaviour.PartInstance.TryGetComponent <IMovementProcessor>(out var movementProcessor))
            {
                return;
            }

            movementInputBehaviour.SetMovementBehaviour(movementBehaviour);

            this.movementProcessor = movementProcessor;
        }
コード例 #3
0
        public void Setup()
        {
            IPacManMovementCommands pacmanMovementCommands = new PacManMovementCommands();

            movementProcessor = new Pacman_Movement_Service.Implementations.MovementProcessor(pacmanMovementCommands);
        }
コード例 #4
0
ファイル: MoveCommand.cs プロジェクト: Argent78/LibToyBot
 public MoveCommand(Stack <Call> callStack, IMovementProcessor movementProcessor)
 {
     _callStack         = callStack;
     _movementProcessor = movementProcessor;
 }
コード例 #5
0
 public void Clear() => movementProcessor = null;
コード例 #6
0
 public MovementProcessorTest()
 {
     BuildServices();
     _movementProcessor = serviceProvider.GetService <IMovementProcessor>();
     _positionTracker   = serviceProvider.GetService <IPositionTracker>();
 }