Esempio n. 1
0
 public void TestLuckyMusicPlaying()
 {
     GameForm form = new GameForm(true, false, 2);
     form.Show();
     form.StartGame(true, false, 2);
     Assert.IsTrue(form.Music.SoundLocation == @"../../Resources/GetLucky2.wav");
 }
Esempio n. 2
0
 public void TestCenaMusicPlaying()
 {
     GameForm form = new GameForm(false, true, 2);
     form.Show();
     form.StartGame(false, true, 2);
     Assert.IsTrue(form.Music.SoundLocation == @"../../Resources/JohnCena.wav");
 }
Esempio n. 3
0
 public void TestReadHighScores()
 {
     GameForm form = new GameForm (false, true, 2);
     form.Show ();
     form.StartGame(true, false, 2);
     form.Die ();
     StringAssert.Contains (Settings.Score.ToString(), form.gameOver);
 }
Esempio n. 4
0
 public void TestGameMessages()
 {
     GameForm form = new GameForm(false,false,2);
     form.Show();
     Assert.IsTrue(form.lblScore.Visible, "Checks if lblScore is visible");
 }
Esempio n. 5
0
 public void TestWriteHighScores()
 {
     GameForm form = new GameForm (false, true, 2);
     form.Show ();
     form.StartGame(true, false, 2);
     form.Die ();
     Assert.AreEqual(Settings.Score, form.iHighScores[form.iHighScores.LastIndexOf(Settings.Score)]);
 }
Esempio n. 6
0
        //Tests methods
        public void StartGame()
        {
            MenuMusic.Stop();

            GameForm game;
            if (a == true || changed == true)
            {
                game = new GameForm(a, c, d);
                this.Hide();
                game.Show();
            }
            else
            {
                game = new GameForm(false, false, 1);
            }
        }
Esempio n. 7
0
 /// <summary>
 /// Starts Game
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 public void StartGame(object sender, EventArgs e)
 {
     GameForm game;
     if (a == true || changed == true)
     {
         game = new GameForm(a, c, d);
         this.Hide();
         game.Show();
     }
     else
     {
         game = new GameForm(false,false,1);
     }
 }