protected void RunTest(string testName, Action <IEnumerable <RegistrationInfo> > action) { string fileName = testName + Extension; var dataPath = new DirectoryInfo(Path.Combine(SolutionItemsBasePath, RelativeTypesPath)); var fileSet = dataPath.GetFiles("*.cs").SelectNotNull(fileInfo => Path.Combine(RelativeTypesPath, fileInfo.Name)).Concat(new[] { fileName }); WithSingleProject(fileSet, (lifetime, project) => RunGuarded(() => { var searchDomainFactory = ShellInstance.GetComponent <SearchDomainFactory>(); var patternSearcher = new PatternSearcher(searchDomainFactory); var solutionnAnalyzer = new SolutionAnalyzer(patternSearcher); solutionnAnalyzer.AddContainer(ContainerInfo); var componentRegistrations = solutionnAnalyzer.Analyze(); action(componentRegistrations); })); }