Пример #1
0
        public void should_not_download_video_when_invalid_save_folder_informed()
        {
            var service  = new TestableVideoService(FakeYouTubeWrapper);
            var filename = service.Download(null);

            Assert.IsTrue(string.IsNullOrEmpty(filename));
        }
Пример #2
0
        public void should_download_video_when_informed_youtubewrapper_and_save_folder()
        {
            var service  = new TestableVideoService(FakeYouTubeWrapper);
            var filename = service.Download(@"C:\Temp");

            Assert.IsTrue(!string.IsNullOrEmpty(filename));
        }
Пример #3
0
        public void should_fail_download_when_cannot_save_on_disk()
        {
            var service = new TestableVideoService(FakeYouTubeWrapper)
            {
                FailOnSaveToDisk = true
            };
            var filename = service.Download(null);

            Assert.IsTrue(string.IsNullOrEmpty(filename));
        }