Beispiel #1
0
        static void Run(string[] args)
        {
            Console.CancelKeyPress += ConsoleCancelKeyPress;
            var options = new StressTestOptions();

            options.Parse(args);

            if (options.Help)
            {
                options.ShowHelp();
                return;
            }

            bool success = true;

            app = new StressTestApp(options);

            try {
                app.Start();
            } catch {
                success = false;

                using (var p = Process.Start("/usr/sbin/screencapture", "screenshot-failure.png")) {
                    Console.WriteLine("Taking screenshot at point of failure");
                    p.WaitForExit();
                }
                throw;
            } finally {
                app.Stop(success);
            }
        }
Beispiel #2
0
        static void Run(string[] args)
        {
            Console.CancelKeyPress += ConsoleCancelKeyPress;
            var options = new StressTestOptions();

            options.Parse(args);

            if (options.Help)
            {
                options.ShowHelp();
                return;
            }

            bool success = true;

            app = new StressTestApp(options);

            try {
                app.Start();
            } catch {
                success = false;
                throw;
            } finally {
                app.Stop(success);
            }
        }
Beispiel #3
0
        static void Run(string[] args)
        {
            Console.CancelKeyPress += ConsoleCancelKeyPress;
            var options = new StressTestOptions();

            options.Parse(args);

            if (options.Help)
            {
                options.ShowHelp();
                return;
            }

            app = new StressTestApp(options);
            app.Start();
            app.Stop();
        }
Beispiel #4
0
        public static ITestScenario GetTestScenario()
        {
            string mainPath      = StressTestApp.GetMonoDevelopMainPath();
            string filesRootPath = Path.Combine(mainPath, "external/mono-addins");

            var scenario = new TestScenario(
                Path.Combine(mainPath, "tests/StressTest/TestProject/TestProject.sln"),
                new [] {
                Path.Combine(filesRootPath, "Mono.Addins/Mono.Addins/Addin.cs"),
                Path.Combine(filesRootPath, "Mono.Addins/Mono.Addins.Localization/StringResourceLocalizer.cs"),
                Path.Combine(filesRootPath, "Mono.Addins/Mono.Addins.Description/AddinDescription.cs"),
                "Program.cs"
            }
                );

            scenario.TextToEnter = new [] { "using S", "yst", "em;" };

            return(scenario);
        }