public void When_StartPuzzleMessage_is_received_Should_set_the_GameId_property_on_the_PuzzleBoardViewModel()
        {
            var fakePuzzleService = new FakePuzzlesService();

            var puzzleBoardVm = new PuzzleBoardViewModel(fakePuzzleService, new TestSchedulers(), new FakeUserSevice());
            fakePuzzleService.AddWords(new Dictionary<string, string>
                                           {
                                               {"Bamidele", "Adetoro's first name"},
                                               {"station", "place where i fit get train"},
                                               {"india", "Origin of my favourite curry"},
                                           });

            var puzzleViewModel = new PuzzleViewModel() { PuzzleId = 1 };
            puzzleBoardVm.LoadState(puzzleViewModel, new Dictionary<string, object>());
            Assert.AreEqual(puzzleViewModel.PuzzleId, puzzleBoardVm.PuzzleViewModel.PuzzleId);
        }
        public async Task When_StartPauseCommand_is_executed_should_get_from_PuzzleService_words_for_the_provided_puzzleId()
        {
            var fakePuzzleService = new FakePuzzlesService();

            var puzzleBoardVm = new PuzzleBoardViewModel(fakePuzzleService, new TestSchedulers(), new FakeUserSevice());
            fakePuzzleService.AddWords(new Dictionary<string, string>
                                           {
                                               {"Bamidele", "Adetoro's first name"},
                                               {"station", "place where i fit get train"},
                                               {"india", "Origin of my favourite curry"},
                                           });

            var puzzleViewModel = new PuzzleViewModel() {PuzzleId = 1};
            puzzleBoardVm.LoadState(puzzleViewModel,new Dictionary<string, object>());
            puzzleBoardVm.StartPauseCommand.Execute(null);
            Assert.AreEqual(3, puzzleBoardVm.Words.Count);
        }
        public static TestPuzzleBoardViewModel PuzzleBoardWith3Words()
        {
                var fakePuzzleService = new FakePuzzlesService();

                fakePuzzleService.AddWords(new Dictionary<string, string>
                                           {
                                               {"Bamidele", "Adetoro's first name"},
                                               {"station", "place where i fit get train"},
                                               {"india", "Origin of my favourite curry"},
                                           });
            var puzzleBoardViewModel = new TestPuzzleBoardViewModel(fakePuzzleService, new TestSchedulers(), new FakeUserSevice());
            var puzzleVm = new PuzzleViewModel() { PuzzleId = 1 };
            puzzleBoardViewModel.LoadState(puzzleVm, new Dictionary<string, object>());
            return puzzleBoardViewModel;
        }
        public void Board_should_be_disabled_if_game_is_not_running()
        {
            var fakePuzzleService = new FakePuzzlesService();
            var puzzleBoardVm = new PuzzleBoardViewModel(fakePuzzleService, new TestSchedulers(), new FakeUserSevice());
            fakePuzzleService.AddWords(new Dictionary<string, string>
                                           {
                                               {"Bamidele", "Adetoro's first name"},
                                               {"station", "place where i fit get train"},
                                               {"india", "Origin of my favourite curry"},
                                           });

            var puzzleViewModel = new PuzzleViewModel() { PuzzleId = 1 };
            puzzleBoardVm.LoadState(puzzleViewModel, new Dictionary<string, object>());

            puzzleBoardVm.StartPauseCommand.Execute(null);
            Assert.IsTrue(puzzleBoardVm.GameIsRunning);
        }