public void If_Error_Exists_Command_Notifies_With_FFmpegException() { // Arrange const string resouceUriReference = "rtmp://error"; MediaInfoFFmpegCmd resInfoFFmpegCmd = new MediaInfoFFmpegCmd(resouceUriReference); MediaInfo mediaInfo = null; resInfoFFmpegCmd.Notify += info => mediaInfo = info; // Act resInfoFFmpegCmd.Execute(); // Assert }
public void Can_Execute_Command() { // Arrange const string resouceUriReference = "rtmp://85.25.122.231/streamHD/video/stream live=1"; MediaInfoFFmpegCmd resInfoFFmpegCmd = new MediaInfoFFmpegCmd(resouceUriReference); MediaInfo mediaInfo = null; resInfoFFmpegCmd.Notify += info => mediaInfo = info; // Act resInfoFFmpegCmd.Execute(); // Assert Assert.IsNotNull(mediaInfo); Assert.IsNotNull(mediaInfo.Format.Bitrate); }