public void CopyContent_Test() { var contentPath = CopyPublishedContent.GetContentFolder(); var fakeStorage = new FakeIStorage(new List<string>{contentPath}, new List<string> { Path.Combine(contentPath, "copy.jsx") }, new List<byte[]>{new byte[0]}); var service = new CopyPublishedContent(new AppSettings(), new ToCreateSubfolder(fakeStorage), new FakeSelectorStorage(fakeStorage)); var content = service.CopyContent( new AppSettingsPublishProfiles(), "/"); Assert.IsTrue(content["copy.jsx"]); }
public WebHtmlPublishService(IPublishPreflight publishPreflight, ISelectorStorage selectorStorage, AppSettings appSettings, IExifToolHostStorage exifTool, IOverlayImage overlayImage, IConsole console, IWebLogger logger) { _publishPreflight = publishPreflight; _subPathStorage = selectorStorage.Get(SelectorStorage.StorageServices.SubPath); _thumbnailStorage = selectorStorage.Get(SelectorStorage.StorageServices.Thumbnail); _hostFileSystemStorage = selectorStorage.Get(SelectorStorage.StorageServices.HostFilesystem); _appSettings = appSettings; _exifTool = exifTool; _console = console; _overlayImage = overlayImage; _publishManifest = new PublishManifest(_hostFileSystemStorage, new PlainTextFileHelper()); _toCreateSubfolder = new ToCreateSubfolder(_hostFileSystemStorage); _copyPublishedContent = new CopyPublishedContent(_appSettings, _toCreateSubfolder, selectorStorage); _logger = logger; _thumbnailService = new Thumbnail(_subPathStorage, _thumbnailStorage, _logger); }