private static void RunTests(Assembly assembly)
    {
        if (assembly == null)
            throw new ArgumentNullException("assembly");

        using (var sw = new StringWriter())
        {
            var runner = new NUnitStreamUI(sw);
            runner.Execute(assembly);
            var resultSummary = runner.Summary;
            var resultText = sw.GetStringBuilder().ToString();
            Presenter(resultText, resultSummary);
        }
    }
        public void RunWithNUnitStreamUI(Assembly assembly)
        {
            if (assembly == null)
            {
                throw new ArgumentNullException("assembly was null.");
            }

            using (var sw = new StringWriter())
            {
                NUnitStreamUI runner = new NUnitStreamUI(sw);
                runner.Execute(assembly);
                ResultSummary resultSummary = runner.Summary;
                string resultText = sw.GetStringBuilder().ToString();
                if (resultSummary.ErrorCount > 0 || resultSummary.FailureCount > 0)
                {
                    Debug.LogWarning(resultText);
                }
                else
                {
                    Debug.Log(resultText);
                }
            }
        }
 private void RunWithNUnitStreamUI(Assembly assembly, String category)
 {
     //Debug.Log("category = " + category);
     using (var sw = new StringWriter())
     {
         NUnitStreamUI runner = new NUnitStreamUI(sw);
         runner.Execute(assembly, category);
         ResultSummary resultSummary = runner.Summary;
         string resultText = sw.GetStringBuilder().ToString();
         if (resultSummary.ErrorCount > 0 || resultSummary.FailureCount > 0)
         {
             Debug.LogWarning(resultText);
         }
         else
         {
             Debug.Log(resultText);
         }
     }
 }