コード例 #1
0
        public bool Parse(string[] args, Configuration configuration, TextWriter stdout)
        {
            configuration.FeatureFolder = new DirectoryInfo(Directory.GetCurrentDirectory());
            configuration.OutputFolder = new DirectoryInfo(Environment.GetEnvironmentVariable("TEMP"));

            List<string> extra = options.Parse(args);

            if (versionRequested)
            {
                DisplayVersion(stdout);
                return false;
            }
            else if (helpRequested)
            {
                DisplayHelp(stdout);
                return false;
            }

            if (!string.IsNullOrEmpty(featureDirectory))
                configuration.FeatureFolder = new DirectoryInfo(featureDirectory);
            if (!string.IsNullOrEmpty(outputDirectory)) configuration.OutputFolder = new DirectoryInfo(outputDirectory);
            if (!string.IsNullOrEmpty(testResultsFormat))
                configuration.TestResultsFormat =
                    (TestResultsFormat) Enum.Parse(typeof (TestResultsFormat), testResultsFormat, true);
            if (!string.IsNullOrEmpty(testResultsFile)) configuration.TestResultsFile = new FileInfo(testResultsFile);
            if (!string.IsNullOrEmpty(systemUnderTestName)) configuration.SystemUnderTestName = systemUnderTestName;
            if (!string.IsNullOrEmpty(systemUnderTestVersion))
                configuration.SystemUnderTestVersion = systemUnderTestVersion;
            if (!string.IsNullOrEmpty(language)) configuration.Language = language;
            if (!string.IsNullOrEmpty(documentationFormat))
                configuration.DocumentationFormat =
                    (DocumentationFormat) Enum.Parse(typeof (DocumentationFormat), documentationFormat, true);

            return true;
        }
コード例 #2
0
 public HtmlDocumentationBuilder(Configuration configuration, DirectoryTreeCrawler featureCrawler, HtmlDocumentFormatter htmlDocumentFormatter, HtmlResourceWriter htmlResourceWriter)
 {
     this.configuration = configuration;
     this.featureCrawler = featureCrawler;
     this.htmlDocumentFormatter = htmlDocumentFormatter;
     this.htmlResourceWriter = htmlResourceWriter;
 }
コード例 #3
0
        public bool Parse(string[] args, Configuration configuration, TextWriter stdout)
        {
            configuration.FeatureFolder = new DirectoryInfo(Directory.GetCurrentDirectory());
            configuration.OutputFolder = new DirectoryInfo(Environment.GetEnvironmentVariable("TEMP"));

            var extra = this.options.Parse(args);

            if (versionRequested)
            {
                DisplayVersion(stdout);
                return false;
            }
            else if (helpRequested)
            {
                DisplayHelp(stdout);
                return false;
            }

            if (!string.IsNullOrWhiteSpace(this.featureDirectory)) configuration.FeatureFolder = new System.IO.DirectoryInfo(this.featureDirectory);
            if (!string.IsNullOrWhiteSpace(this.outputDirectory)) configuration.OutputFolder = new System.IO.DirectoryInfo(this.outputDirectory);
            if (!string.IsNullOrWhiteSpace(this.resultsFile)) configuration.LinkedTestFrameworkResultsFile = new FileInfo(this.resultsFile);
            if (!string.IsNullOrWhiteSpace(this.systemUnderTestName)) configuration.SystemUnderTestName = this.systemUnderTestName;
            if (!string.IsNullOrWhiteSpace(this.systemUnderTestVersion)) configuration.SystemUnderTestVersion = this.systemUnderTestVersion;

            return true;
        }
コード例 #4
0
 public HtmlDocumentationBuilder(Configuration configuration,
                                 HtmlDocumentFormatter htmlDocumentFormatter,
                                 HtmlResourceWriter htmlResourceWriter)
 {
     this.configuration = configuration;
     this.htmlDocumentFormatter = htmlDocumentFormatter;
     this.htmlResourceWriter = htmlResourceWriter;
 }
コード例 #5
0
ファイル: LanguageServices.cs プロジェクト: ppnrao/pickles
 public LanguageServices(Configuration configuration)
 {
     if (!string.IsNullOrEmpty(configuration.Language))
         currentCulture = CultureInfo.GetCultureInfo(configuration.Language);
 }
コード例 #6
0
ファイル: HtmlResourceSet.cs プロジェクト: MikeEast/pickles
 public HtmlResourceSet(Configuration configuration)
 {
     this.configuration = configuration;
 }