content: /*
   * This file was automatically generated by EvoSuite
   */
  
  package com.lts.lang.classloader;
  
  import org.junit.Test;
  import org.junit.runner.RunWith;
  import org.evosuite.junit.EvoSuiteRunner;
  import static org.junit.Assert.*;
  import com.lts.io.IndentingPrintWriter;
  import com.lts.lang.classloader.DebugClassLoader;
  import java.io.CharArrayWriter;
  import java.io.IOException;
  import java.io.OutputStream;
  import java.io.PipedInputStream;
  import java.io.PipedOutputStream;
  import java.io.PrintStream;
  import java.io.PrintWriter;
  import java.io.StringWriter;
  import java.io.Writer;
  import org.junit.BeforeClass;
  
  @RunWith(EvoSuiteRunner.class)
  public class DebugClassLoaderEvoSuiteTest {
  
    @BeforeClass 
    public static void initEvoSuiteFramework(){ 
      org.evosuite.Properties.REPLACE_CALLS = true; 
    } 
  
  
    @Test
    public void test0()  throws Throwable  {
        String[] stringArray0 = new String[7];
        try {
          DebugClassLoader.debugClass("f%/A`.k[St~XxN{", stringArray0, "f%/A`.k[St~XxN{");
          fail("Expecting exception: IOException");
        } catch(IOException e) {
          /*
           * Could not create parent director for logfile, f%
           */
        }
    }
  
    @Test
    public void test1()  throws Throwable  {
        StringWriter stringWriter0 = new StringWriter();
        PrintWriter printWriter0 = new PrintWriter((Writer) stringWriter0);
        String[] stringArray0 = new String[9];
        stringArray0[0] = "f0F n";
        stringArray0[1] = "f0F n";
        stringArray0[2] = "javax.0F n";
        stringArray0[3] = "f0F n";
        stringArray0[4] = "f0F n";
        stringArray0[5] = "f0F n";
        stringArray0[6] = "FO/L7-oP1lm9";
        stringArray0[7] = "f0F n";
        stringArray0[8] = "f0F n";
        DebugClassLoader debugClassLoader0 = new DebugClassLoader(stringArray0, printWriter0, (ClassLoader) null);
        // Undeclared exception!
        try {
          debugClassLoader0.loadClass("javax.0F n", false);
          fail("Expecting exception: NullPointerException");
        } catch(NullPointerException e) {
        }
    }
  
    @Test
    public void test2()  throws Throwable  {
        String[] stringArray0 = new String[1];
        stringArray0[0] = "";
        PipedOutputStream pipedOutputStream0 = new PipedOutputStream();
        PrintStream printStream0 = new PrintStream((OutputStream) pipedOutputStream0);
        DebugClassLoader.debugClass("com.sun.M\"", stringArray0, printStream0);
        assertEquals(true, printStream0.checkError());
    }
  
    @Test
    public void test3()  throws Throwable  {
        String[] stringArray0 = new String[4];
        stringArray0[0] = "0F n";
        stringArray0[1] = "0F n";
        stringArray0[2] = "0F n";
        stringArray0[3] = "0F n";
        CharArrayWriter charArrayWriter0 = new CharArrayWriter();
        IndentingPrintWriter indentingPrintWriter0 = new IndentingPrintWriter((Writer) charArrayWriter0);
        ClassLoader classLoader0 = ClassLoader.getSystemClassLoader();
        DebugClassLoader debugClassLoader0 = new DebugClassLoader(stringArray0, (PrintWriter) indentingPrintWriter0, classLoader0);
        debugClassLoader0.getRepositoryFiles();
        assertEquals(164, charArrayWriter0.size());
        assertEquals("warning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\n", charArrayWriter0.toString());
    }
  
    @Test
    public void test4()  throws Throwable  {
        String[] stringArray0 = new String[4];
        stringArray0[0] = "0F n";
        stringArray0[1] = "0F n";
        stringArray0[2] = "0F n";
        stringArray0[3] = "0F n";
        CharArrayWriter charArrayWriter0 = new CharArrayWriter();
        IndentingPrintWriter indentingPrintWriter0 = new IndentingPrintWriter((Writer) charArrayWriter0);
        ClassLoader classLoader0 = ClassLoader.getSystemClassLoader();
        DebugClassLoader debugClassLoader0 = new DebugClassLoader(stringArray0, (PrintWriter) indentingPrintWriter0, classLoader0);
        String[] stringArray1 = new String[9];
        debugClassLoader0.setRepositoryFiles(stringArray1);
        assertEquals(164, charArrayWriter0.size());
        assertEquals("warning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\n", charArrayWriter0.toString());
    }
  
    @Test
    public void test5()  throws Throwable  {
        try {
          DebugClassLoader.openLogfile("/Create", true);
          fail("Expecting exception: IOException");
        } catch(IOException e) {
          /*
           * Could not create parent director for logfile, /
           */
        }
    }
  
    @Test
    public void test6()  throws Throwable  {
        String[] stringArray0 = new String[3];
        stringArray0[1] = "coLTz.";
        stringArray0[2] = "coLTz.";
        CharArrayWriter charArrayWriter0 = new CharArrayWriter();
        stringArray0[0] = "/";
        PrintWriter printWriter0 = new PrintWriter((Writer) charArrayWriter0);
        DebugClassLoader.debugClass("coLTz.", stringArray0, printWriter0);
        assertEquals("warning: repository does not exist, coLTz.\nwarning: repository does not exist, coLTz.\nTrying to load: coLTz.\n\tClasspath: /fastdata/ac1gf/SF110/evosuite-0.1-SNAPSHOT-jar-minimal.jar:lib/jlfgr-1_0.jar:lib/swingx-0.9.2.jar:lib/swingx.jar:caloriecount.jar\n\nRepositories:\n\t/\n\tcoLTz.\n\t\tRepository does not exist!\n\tcoLTz.\n\t\tRepository does not exist!\n\ncoLTz.\nClass not found, lookup trace: \n\nException:\njava.lang.ClassNotFoundException: coLTz.\n\tat com.lts.lang.classloader.BasicClassLoader.findClass(BasicClassLoader.java:198)\n\tat com.lts.lang.classloader.DebugClassLoader.loadClass(DebugClassLoader.java:375)\n\tat com.lts.lang.classloader.DebugClassLoader.loadClass(DebugClassLoader.java:397)\n\tat java.lang.Class.forName0(Native Method)\n\tat java.lang.Class.forName(Class.java:247)\n\tat com.lts.lang.classloader.DebugClassLoader.debugClass(DebugClassLoader.java:229)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)\n\tat java.lang.reflect.Method.invoke(Method.java:597)\n\tat org.evosuite.testcase.MethodStatement$1.execute(MethodStatement.java:262)\n\tat org.evosuite.testcase.AbstractStatement.exceptionHandler(AbstractStatement.java:142)\n\tat org.evosuite.testcase.MethodStatement.execute(MethodStatement.java:217)\n\tat org.evosuite.testcase.TestRunnable.call(TestRunnable.java:291)\n\tat org.evosuite.testcase.TestRunnable.call(TestRunnable.java:44)\n\tat java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)\n\tat java.util.concurrent.FutureTask.run(FutureTask.java:138)\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)\n\tat java.lang.Thread.run(Thread.java:662)\n", charArrayWriter0.toString());
        assertEquals(1869, charArrayWriter0.size());
    }
  
    @Test
    public void test7()  throws Throwable  {
        String[] stringArray0 = new String[4];
        stringArray0[0] = "0F n";
        stringArray0[1] = "0F n";
        stringArray0[2] = "0F n";
        stringArray0[3] = "0F n";
        CharArrayWriter charArrayWriter0 = new CharArrayWriter();
        IndentingPrintWriter indentingPrintWriter0 = new IndentingPrintWriter((Writer) charArrayWriter0);
        Object[] objectArray0 = new Object[7];
        ClassLoader classLoader0 = ClassLoader.getSystemClassLoader();
        DebugClassLoader debugClassLoader0 = new DebugClassLoader(stringArray0, (PrintWriter) indentingPrintWriter0, classLoader0);
        debugClassLoader0.logEvent((-1), objectArray0);
        assertEquals("warning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\nwarning: repository does not exist, 0F n\n", charArrayWriter0.toString());
        assertEquals(164, charArrayWriter0.size());
    }
  
    @Test
    public void test8()  throws Throwable  {
        String[] stringArray0 = new String[6];
        stringArray0[0] = "java.Gl6zLr>`>FF#x";
        stringArray0[1] = "java.Gl6zLr>`>FF#x";
        stringArray0[2] = "java.Gl6zLr>`>FF#x";
        stringArray0[3] = "java.Gl6zLr>`>FF#x";
        stringArray0[4] = "java.Gl6zLr>`>FF#x";
        stringArray0[5] = "java.Gl6zLr>`>FF#x";
        PipedInputStream pipedInputStream0 = new PipedInputStream();
        PipedOutputStream pipedOutputStream0 = new PipedOutputStream(pipedInputStream0);
        IndentingPrintWriter indentingPrintWriter0 = new IndentingPrintWriter((OutputStream) pipedOutputStream0);
        DebugClassLoader.debugClass("java.Gl6zLr>`>FF#x", stringArray0, (PrintWriter) indentingPrintWriter0);
    }
  }
  