예제 #1
0
    public static void StartTest(string name)
    {
        var baseDir = AppDomain.CurrentDomain.BaseDirectory;

        if (testRunner != null)
        {
            throw new Exception("Test in progress");
        }

        string extra_disable = "";

        string[] args           = name.Split(',');
        var      testsuite_name = suites.Where(ts => ts.Name == args [0]).Select(ts => ts.File).FirstOrDefault();

        if (testsuite_name == null)
        {
            throw new Exception("NO SUITE NAMED " + args [0]);
        }

        string test_name = null;
        int?   range     = null;

        for (int i = 1; i < args.Length; ++i)
        {
            int r;
            if (int.TryParse(args [i], out r))
            {
                range = r;
            }
            else
            {
                test_name = args [i];
            }
        }

        testRunner = new IncrementalTestRunner();
        // testRunner.PrintLabels ();
        // if (test_name != null)
        //  testRunner.RunTest (test_name);

        testRunner.Exclude("WASM,NotWorking,ValueAdd,CAS,InetAccess");
        testRunner.Add(Assembly.LoadFrom(baseDir + "/" + testsuite_name));
        // testRunner.RunOnly ("MonoTests.System.Threading.AutoResetEventTest.MultipleSet");

        testRunner.Start(10);
    }
예제 #2
0
파일: main.cs 프로젝트: teddydragoone/mono
    public static void StartTest(string name)
    {
        var baseDir = AppDomain.CurrentDomain.BaseDirectory;

        if (testRunner != null)
        {
            throw new Exception("Test in progress");
        }

        if (name == "tp")
        {
            TPStart();
            return;
        }
        if (name == "dele")
        {
            DeleStart();
            return;
        }
        if (name == "gc")
        {
            GcStart();
            return;
        }
        if (name == "timer")
        {
            TimerStart();
            return;
        }

        string extra_disable = "";

        latest_test_result = "IN-PROGRESS";

        string[] args           = name.Split(',');
        var      testsuite_name = suites.Where(ts => ts.Name == args [0]).Select(ts => ts.File).FirstOrDefault();

        if (testsuite_name == null)
        {
            throw new Exception("NO SUITE NAMED " + args [0]);
        }

        string test_name = null;
        int?   range     = null;

        for (int i = 1; i < args.Length; ++i)
        {
            int r;
            if (int.TryParse(args [i], out r))
            {
                range = r;
            }
            else
            {
                test_name = args [i];
            }
        }

        testRunner = new IncrementalTestRunner();
        // testRunner.PrintLabels ();
        // if (test_name != null)
        //  testRunner.RunTest (test_name);

        testRunner.Exclude("NotWasm,WASM,NotWorking,ValueAdd,CAS,InetAccess,NotWorkingRuntimeInterpreter,MultiThreaded");
        testRunner.Add(Assembly.LoadFrom(baseDir + "/" + testsuite_name));
        // testRunner.RunOnly ("MonoTests.System.Threading.AutoResetEventTest.MultipleSet");

        // This is useful if you need to skip to the middle of a huge test suite like corlib.
        // testRunner.SkipFirst (4550);
        testRunner.Start(10);
    }