Пример #1
0
 public void  ExtractProjectsFromSolutionFileExistsNoExceptionExpected()
 {
     // Arrange
     // use default solution file.
     // Act
     extractor = new SolutionExtractor(Constants.SolutionFileLocation);
     //Assert
     extractor.Extract();
 }
Пример #2
0
        public void ExtractProjectsFromSolutionFileDoesNotExist()
        {
            //Arrange
            const string solutionName = @"C:\Users\Richard\source\repos\NITRPackager\SampleSolution\DownloadFromNetTaskFactory1\DownloadFromNetTaskFactory.sln";

            //Act
            extractor = new SolutionExtractor(solutionName);
            //ASSERT
            var ex = Assert.ThrowsException <FileNotFoundException>(() => extractor.Extract());
        }
Пример #3
0
        public void ExtractProjectDetailsFromSolutionFile()
        {
            //Arrange
            var expectedProjects = 1;

            // Act
            extractor = new SolutionExtractor(Constants.SolutionFileLocation);
            extractor.Extract();
            // Assert
            Assert.IsTrue(expectedProjects == extractor.Projects.Count());

            foreach (ProjectDetail currentProjectDetail in extractor.Projects)
            {
                Console.WriteLine($"{currentProjectDetail.Name} {currentProjectDetail.Location}");
            }
        }
Пример #4
0
 public SATPlan(SATSolver satSolver, SolutionExtractor solutionExtractor)
 {
     this.satSolver         = satSolver;
     this.solutionExtractor = solutionExtractor;
 }
Пример #5
0
 public void Initialise()
 {
     // baseline initialise extractor object.
     extractor = new SolutionExtractor(Constants.SolutionFileLocation);
 }