protected override string GetConfigFileContent() { ProjectItem projectItem = VsxHelper.FindProjectItemByProjectRelativePath(project, "app.config"); if (projectItem == null) { return(null); } return(VsxHelper.GetFileContent(projectItem, true)); }
public SpecFlowConfigurationHolder ReadConfiguration() { ProjectItem projectItem = VsxHelper.FindProjectItemByProjectRelativePath(project, "app.config"); if (projectItem == null) { return(new SpecFlowConfigurationHolder()); } string configFileContent = VsxHelper.GetFileContent(projectItem); return(GetConfigurationHolderFromFileContent(configFileContent)); }
private static SpecFlowProjectConfiguration LoadSpecFlowConfigurationFromDteProjectInternal(Project project) { SpecFlowProjectConfiguration configuration = new SpecFlowProjectConfiguration(); ProjectItem projectItem = VsxHelper.FindProjectItemByProjectRelativePath(project, "app.config"); if (projectItem != null) { string configFileContent = VsxHelper.GetFileContent(projectItem); GeneratorConfigurationReader.UpdateConfigFromFileContent(configuration.GeneratorConfiguration, configFileContent); RuntimeConfigurationReader.UpdateConfigFromFileContent(configuration.RuntimeConfiguration, configFileContent); } return(configuration); }
public SpecFlowConfigurationHolder ReadConfiguration(IProjectReference projectReference) { var vsProjectReference = VsProjectReference.AssertVsProjectReference(projectReference); ProjectItem projectItem = VsxHelper.FindProjectItemByProjectRelativePath(vsProjectReference.Project, "app.config"); if (projectItem == null) { return(new SpecFlowConfigurationHolder()); } string configFileContent = VsxHelper.GetFileContent(projectItem); return(GetConfigurationHolderFromFileContent(configFileContent)); }