public void SetUp() { eventDispatcher = Substitute.For <IEventDispatcher> (); calculateTouchCommand = new CalculateTouchCommand(); calculateTouchCommand.eventDispatcher = eventDispatcher; eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); eventDispatcher = Substitute.For <IEventDispatcher> (); allowFallingTilesCommand = new AllowFallingTilesCommand(); allowFallingTilesCommand.matchTileGridModel = matchTileGridModel; allowFallingTilesCommand.eventDispatcher = eventDispatcher; eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); eventDispatcher = Substitute.For <IEventDispatcher> (); checkMovesRemainingCommand = new CheckMovesRemainingCommand(); checkMovesRemainingCommand.matchTileGridModel = matchTileGridModel; checkMovesRemainingCommand.eventDispatcher = eventDispatcher; eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); eventDispatcher = Substitute.For <IEventDispatcher> (); shuffleGridCommand = new ShuffleGridCommand(); shuffleGridCommand.matchTileGridModel = matchTileGridModel; shuffleGridCommand.eventDispatcher = eventDispatcher; eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); matchTileFactory = Substitute.For <IMatchTileFactory>(); eventDispatcher = Substitute.For <IEventDispatcher> (); createMatchTileGridCommand = new CreateMatchTileGridCommand(); createMatchTileGridCommand.matchTileGridModel = matchTileGridModel; createMatchTileGridCommand.matchTileFactory = matchTileFactory; createMatchTileGridCommand.eventDispatcher = eventDispatcher; eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); eventDispatcher = Substitute.For <IEventDispatcher> (); calculateTilesToRemoveCommand = new CalculateTilesToRemoveCommand(); calculateTilesToRemoveCommand.matchTileGridModel = matchTileGridModel; calculateTilesToRemoveCommand.eventDispatcher = eventDispatcher; matchTileGridModel.allowTouch = true; eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); matchTileGridModel.gridHolder = new GameObject(); eventDispatcher = Substitute.For <IEventDispatcher> (); createMatchTileGridHolderCommand = new CreateMatchTileGridHolderCommand(); createMatchTileGridHolderCommand.matchTileGridModel = matchTileGridModel; createMatchTileGridHolderCommand.eventDispatcher = eventDispatcher; MatchTilesData matchTilesData = ScriptableObject.CreateInstance <MatchTilesData> (); matchTileGridModel.matchTilesData.Returns(matchTilesData); eventDispatcher.CleanAndDestroy(); }
public void SetUp() { matchTileGridModel = Substitute.For <IMatchTileGridModel>(); eventDispatcher = Substitute.For <IEventDispatcher> (); matchTileTouchedCommand = new MatchTileTouchedCommand(); matchTileTouchedCommand.matchTileGridModel = matchTileGridModel; matchTileTouchedCommand.eventDispatcher = eventDispatcher; GameObject gameObject = new GameObject(); gameObject.transform.localPosition = Vector3.zero; TouchedObject touchedObject = new TouchedObject(); touchedObject.objectHit = gameObject; matchTileTouchedCommand.touchedObject = touchedObject; eventDispatcher.CleanAndDestroy(); }