Beispiel #1
0
        public void PlayMethodUnofficialHeadsetConsoleTest()
        {
            //Arrange
            UnitTestConsoleOutput console = new UnitTestConsoleOutput();
            var expected = $"Play sound in Mobile:\n{nameof(PlayBackUnofficialHeadset)} sound";
            //Act
            PlayBackUnofficialHeadset ActIPhone = new PlayBackUnofficialHeadset(console);

            ActIPhone.Play();
            //Assert
            Assert.AreEqual(expected, console.GetText());
        }
Beispiel #2
0
        public void PlayMethodPhoneSpeakerConsoleTest()
        {
            //Arrange
            UnitTestConsoleOutput console = new UnitTestConsoleOutput();
            var expected = $"Play sound in Mobile:\n{nameof(PlayBackPhoneSpeaker)} sound";
            //Act
            PlayBackPhoneSpeaker ActIPhone = new PlayBackPhoneSpeaker(console);

            ActIPhone.Play();
            //Assert
            Assert.AreEqual(expected, console.GetText());
        }