//adds the deck to the game public ISolitaireGameInstance CreateGameInstance() { IDeckFactory deckFactory = new StandardDeckFactory(); IDeck deck = deckFactory.CreateDeck(); ISolitaireGameInstance gameInstance = new SolitaireGameInstance(deck); return(gameInstance); }
//couldnt figure out how to make this work, but what it would do is test the deck stack public void TestConstructor() { IDeckFactory deckFactory = new StandardDeckFactory(); IDeck deck = deckFactory.CreateDeck(); ISolitaireGameInstance game = new SolitaireGameInstance(deck); IEventAggregator eventAggregator = new EventAggregator(); var viewModel = new OverflowCardStackViewModel(game, eventAggregator); Assert.AreEqual(viewModel.TopCard, game.OverflowStack[game.OverflowStack.Count - 1]);