public RecordingSession() { _tempFile = new TempFile(); _recorder = AudioFactory.CreateAudioSession(_tempFile.Path); _recorder.StartRecording(); Thread.Sleep(100); }
public void RecordThenStop_CanPlay_IsTrue() { using (var f = new TempFile()) { ISimpleAudioSession x = RecordSomething(f); Assert.IsTrue(x.CanPlay); } }
public void IsRecording_AfterRecording_False() { using (var f = new TempFile()) { ISimpleAudioSession x = RecordSomething(f); Assert.IsFalse(x.IsRecording); } }
public void RecordThenPlay_OK() { using (var f = new TempFile()) { ISimpleAudioSession x = RecordSomething(f); x.Play(); Thread.Sleep(100); // Ensure file exists to be played. x.StopPlaying(); } }
public void RecordThenPlay_OK() { using (var f = new TempFile()) { using (ISimpleAudioSession x = RecordSomething(f)) { x.Play(); Thread.Sleep(100); x.StopPlaying(); } } }