Exemplo n.º 1
0
        public void NewCharTile_InitialisationWithLowerCaseChar_ThrowExceptionThatCharMustBeUppercase()
        {
            CharTile c;

            UnitTestGlobals.InvokeActionAndAssertThatCorrectExceptionMessageIsThrown(() => c = new CharTile('a'), ExceptionMessages.LetterCanOnlyBeBetweenAAndZ);
        }
Exemplo n.º 2
0
        public void BoingDawg_ReadDawg_CountMustBe64()
        {
            Dawg <bool> boingDawg = UnitTestGlobals.LoadBoingDawgFile();

            Assert.IsTrue(boingDawg.Count() == 64);
        }
Exemplo n.º 3
0
        public void NewCharTile_InitialisationWith0Score_ThrowExceptionThatScoreMustBeMoreThan0()
        {
            CharTile c;

            UnitTestGlobals.InvokeActionAndAssertThatCorrectExceptionMessageIsThrown(() => c = new CharTile('A', 0), ExceptionMessages.ScoreMustBeGreaterThan0);
        }
Exemplo n.º 4
0
        public void NewBoard_CreationWithBadRowCount_IncorrectRowNumberExceptionIsThrown()
        {
            Board board;

            UnitTestGlobals.InvokeActionAndAssertThatCorrectExceptionMessageIsThrown(() => board = new Board(0, 1), ExceptionMessages.BoardMustHaveAtLeastOneRow);
        }