Example #1
0
        private static void Uploader()
        {
            var coverage = new Coverage.Tool.Coverage(_commandLineOptions);
            var envVars  = new EnviornmentVariables(_commandLineOptions);
            var continuousIntegrationServer = ContinuousIntegrationServerFactory.Create(envVars);

            envVars.LoadEnviornmentVariables(continuousIntegrationServer);
            var terminals            = TerminalFactory.Create();
            var versionControlSystem = VersionControlSystemFactory.Create(_commandLineOptions, terminals[TerminalName.Generic]);
            var sourceCode           = new SourceCode(versionControlSystem);
            var yaml         = new Yaml.Yaml(sourceCode);
            var repositories = RepositoryFactory.Create(versionControlSystem, continuousIntegrationServer);
            var url          = new Url.Url(new Host(_commandLineOptions, envVars), new Route(), new Query(_commandLineOptions, repositories, continuousIntegrationServer, yaml, envVars));
            var report       = new Report(_commandLineOptions, envVars, sourceCode, coverage);
            var upload       = new Uploads(url, report, _commandLineOptions.Features);
            var uploadFacade = new UploadFacade(continuousIntegrationServer, versionControlSystem, yaml, coverage, envVars, url, upload);

            uploadFacade.LogContinuousIntegrationAndVersionControlSystem();
            if (_commandLineOptions.Dump)
            {
                Log.Warning("Skipping upload and dumping contents.");
                Log.Information("url: {GetUrl}", url.GetUrl);
                Log.Information(report.Reporter);
                return;
            }

            uploadFacade.UploadReports();
        }
Example #2
0
        private static void Uploader()
        {
            var upload = new UploadFacade(_commandLineOptions);

            upload.Uploader();
        }