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()); }
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()); }