Ejemplo n.º 1
0
 public static void RunUnitTests()
 {
     var resultFilePath = GetParameterArgument (resultFilePathParam) ?? Directory.GetCurrentDirectory ();
     if (Directory.Exists (resultFilePath))
         resultFilePath = Path.Combine (resultFilePath, defaultResultFileName);
     EditorApplication.NewScene ();
     var engine = new NUnitTestEngine ();
     UnitTestResult[] results;
     string[] categories;
     engine.GetTests (out results, out categories);
     engine.RunTests (new TestRunnerEventListener (resultFilePath,results.ToList()));
 }
Ejemplo n.º 2
0
        public static void RunUnitTests()
        {
			PlayerSettings.useMacAppStoreValidation = false;
            var filter = GetTestFilter();
            var resultFilePath = GetParameterArgument(k_ResultFilePathParam) ?? Directory.GetCurrentDirectory();
            if (Directory.Exists(resultFilePath))
                resultFilePath = Path.Combine(resultFilePath, k_DefaultResultFileName);
            EditorApplication.NewScene();
            var engine = new NUnitTestEngine();
            UnitTestResult[] results;
            string[] categories;
            engine.GetTests(out results, out categories);
            engine.RunTests(filter, new TestRunnerEventListener(resultFilePath, results.ToList()));
        }
Ejemplo n.º 3
0
        public static void RunUnitTests()
        {
            var resultFilePath = GetParameterArgument(resultFilePathParam) ?? Directory.GetCurrentDirectory();

            if (Directory.Exists(resultFilePath))
            {
                resultFilePath = Path.Combine(resultFilePath, defaultResultFileName);
            }
            EditorApplication.NewScene();
            var engine = new NUnitTestEngine();

            UnitTestResult[] results;
            string[]         categories;
            engine.GetTests(out results, out categories);
            engine.RunTests(new TestRunnerEventListener(resultFilePath, results.ToList()));
        }
Ejemplo n.º 4
0
        public static void RunUnitTests()
        {
            PlayerSettings.useMacAppStoreValidation = false;
            var filter         = GetTestFilter();
            var resultFilePath = GetParameterArgument(k_ResultFilePathParam) ?? Directory.GetCurrentDirectory();

            if (Directory.Exists(resultFilePath))
            {
                resultFilePath = Path.Combine(resultFilePath, k_DefaultResultFileName);
            }
            EditorApplication.NewScene();
            var engine = new NUnitTestEngine();

            UnitTestResult[] results;
            string[]         categories;
            engine.GetTests(out results, out categories);
            engine.RunTests(filter, new TestRunnerEventListener(resultFilePath, results.ToList()));
        }
Ejemplo n.º 5
0
        public static void RunUnitTests()
        {
            PlayerSettings.useMacAppStoreValidation = false;
            var filter         = GetTestFilter();
            var resultFilePath = GetParameterArgument(k_ResultFilePathParam) ?? Directory.GetCurrentDirectory();

            if (Directory.Exists(resultFilePath))
            {
                resultFilePath = Path.Combine(resultFilePath, k_DefaultResultFileName);
            }

#if UNITY_4_6 || UNITY_4_7 || UNITY_5_0 || UNITY_5_1 || UNITY_5_2
            EditorApplication.NewScene();
#else
            UnityEditor.SceneManagement.EditorSceneManager.NewScene(UnityEditor.SceneManagement.NewSceneSetup.DefaultGameObjects);
#endif
            var engine = new NUnitTestEngine();
            UnitTestResult[] results;
            string[]         categories;
            engine.GetTests(out results, out categories);
            engine.RunTests(filter, new TestRunnerEventListener(resultFilePath, results.ToList()));
        }