Пример #1
0
        public void Should_CreateDataAnalysisPipeline_When_Called()
        {
            var sut = new PipelineFactory(Mock.Of <IFileCopier>());

            DataAnalysisPipeline result = (DataAnalysisPipeline)sut.CreateDataAnalysisPipeline(
                new RepositoryUrl("Url"),
                new RepositoryDestination("Destination"));

            Assert.NotNull(result);
        }
Пример #2
0
        public void Should_PassRepositoryDestination_When_DestinationGiven()
        {
            var dest = new RepositoryDestination("destination");
            var sut  = new PipelineFactory(Mock.Of <IFileCopier>());

            DataAnalysisPipeline result = (DataAnalysisPipeline)sut.CreateDataAnalysisPipeline(
                new RepositoryUrl("url"),
                dest);

            Assert.Same(dest, result.RepositoryDestination);
        }
Пример #3
0
        public void Should_PassRepositoryUrlToPipeline_When_UrlGiven()
        {
            var url = new RepositoryUrl("url");
            var sut = new PipelineFactory(Mock.Of <IFileCopier>());

            DataAnalysisPipeline result = (DataAnalysisPipeline)sut.CreateDataAnalysisPipeline(
                url,
                new RepositoryDestination("Destination"));

            Assert.Same(url, result.RepositoryUrl);
        }
Пример #4
0
        public void Should_PassFileCopierToPipeline_When_FileCopierGiven()
        {
            var fileCopierMock = Mock.Of <IFileCopier>();

            var sut = new PipelineFactory(fileCopierMock);

            DataAnalysisPipeline result = (DataAnalysisPipeline)sut.CreateDataAnalysisPipeline(
                new RepositoryUrl("Url"),
                new RepositoryDestination("Destination"));

            Assert.Same(fileCopierMock, result.FileCopier);
        }