Exemple #1
0
        private static int Main(string[] args)
        {
            int returnValue = 0;

            Arguments arguments = new Arguments(args);

            if (arguments.ArgumentsAreValid)
            {
                ScenarioRunner scenarioRunner = new ScenarioRunner(arguments);

                // Run the automation. This will write traces to the current or provided directory if the user requested it
                if (arguments.Browsers.Count > 0 && arguments.Scenarios.Count > 0)
                {
                    scenarioRunner.Run();
                }

                // If traces have been written, process them into a csv of results
                // Only necessary if we're tracing and/or measuring responsiveness
                if ((arguments.UsingTraceController && arguments.DoPostProcessing) || arguments.MeasureResponsiveness)
                {
                    PerfProcessor perfProcessor = new PerfProcessor((arguments.SelectedMeasureSets).ToList());
                    perfProcessor.Execute(arguments.EtlPath, arguments.EtlPath, scenarioRunner.GetResponsivenessResults());
                }
            }
            else
            {
                returnValue = 1;
            }
            return(returnValue);
        }
        private static void Main(string[] args)
        {
            Arguments arguments = new Arguments(args);

            ScenarioRunner scenarioRunner = new ScenarioRunner(arguments);

            scenarioRunner.Run();

            if (arguments.UsingTraceController)
            {
                PerfProcessor perfProcessor = new PerfProcessor((arguments.SelectedMeasureSets).ToList());

                perfProcessor.Execute(arguments.EtlPath, arguments.EtlPath);
            }
        }
Exemple #3
0
        private static int Main(string[] args)
        {
            int returnValue = 0;

            Arguments arguments = new Arguments(args);

            if (arguments.ArgumentsAreValid)
            {
                var         heartBeatCtx  = new CancellationTokenSource();
                Task <bool> heartBeatTask = StartLogHeartBeat(heartBeatCtx, arguments.EtlPath);

                ScenarioRunner scenarioRunner = new ScenarioRunner(arguments);

                // Run the automation. This will write traces to the current or provided directory if the user requested it
                if (arguments.Browsers.Count > 0 && arguments.Scenarios.Count > 0)
                {
                    scenarioRunner.Run();
                }

                // If traces have been written, process them into a csv of results
                // Only necessary if we're tracing and/or measuring responsiveness
                if ((arguments.UsingTraceController && arguments.DoPostProcessing) || arguments.MeasureResponsiveness)
                {
                    PerfProcessor perfProcessor = new PerfProcessor((arguments.SelectedMeasureSets).ToList());
                    perfProcessor.Execute(arguments.EtlPath, arguments.EtlPath, scenarioRunner.GetResponsivenessResults(), ScenarioRunner._extensionsNameAndVersion);
                    generateCharts(arguments.EtlPath, arguments.EtlPath, arguments.GenerateChartsWithSymbols);
                }

                heartBeatCtx.Cancel();
                var heartBeat = heartBeatTask.Result;
            }
            else
            {
                returnValue = 1;
            }
            return(returnValue);
        }