public void CreateScreenshotAdjusterParamTest()
        {
            //Arrange
            var factory = new ScreenshotAdjusterParamFactory();

            //Act
            var screenshotAdjusterParam = factory.CreateScreenshotAdjusterParam(_videoMetadata.Object);

            //Assert
            Assert.AreEqual(_videoMetadata.Object.VideoWidth, screenshotAdjusterParam.ImageWidth);
            Assert.AreEqual(_videoMetadata.Object.VideoHeight, screenshotAdjusterParam.ImageHeight);
            Assert.AreEqual(154.654, screenshotAdjusterParam.Duration);
            Assert.AreEqual(_videoMetadata.Object.VideoRotation, screenshotAdjusterParam.VideoRotation);
        }
        public void CreateScreenshotAdjusterParamThrowAggregateExceptionTest()
        {
            //Arrange
            var factory = new ScreenshotAdjusterParamFactory();
            var videoMetadata0 = new Mock<IVideoMetadata>();
            var videoMetadata1 = new Mock<IVideoMetadata>();
            var videoMetadata2 = new Mock<IVideoMetadata>();

            videoMetadata0.Setup(p=>p.VideoStreamsCount).Returns(0);
            videoMetadata1.Setup(p => p.VideoStreamsCount).Returns(1);
            videoMetadata2.Setup(p => p.VideoStreamsCount).Returns(2);

            //Act & Assert
            var exception0 = ExceptionAssert.Throws<AggregateException>(() => factory.CreateScreenshotAdjusterParam(videoMetadata0.Object));
            var exception2 = ExceptionAssert.Throws<AggregateException>(() => factory.CreateScreenshotAdjusterParam(videoMetadata2.Object));
            ExceptionAssert.NotThrows<AggregateException>(() => factory.CreateScreenshotAdjusterParam(videoMetadata1.Object));

            //Assert
            Assert.IsTrue(exception0.InnerExceptions.OfType<VideoFormatException>().Any(p => p.ParamType == ParamType.VideoStreamCount));
            Assert.IsTrue(exception2.InnerExceptions.OfType<VideoFormatException>().Any(p => p.ParamType == ParamType.VideoStreamCount));
        }