content: /*
   * This file was automatically generated by UTestGen and EvoSuite
   * Thu Mar 21 03:46:02 GMT 2024
   */
  
  package org.objectweb.asm.jip;
  
  import org.junit.jupiter.api.Test;
  import static org.junit.jupiter.api.Assertions.*;
  import org.junit.jupiter.api.Timeout;
  import java.util.concurrent.TimeUnit;
  import static org.evosuite.runtime.EvoAssertions.*;
  import java.io.IOException;
  import org.evosuite.runtime.EvoRunner;
  import org.evosuite.runtime.EvoRunnerParameters;
  import org.junit.runner.RunWith;
  import org.objectweb.asm.jip.Attribute;
  import org.objectweb.asm.jip.ClassReader;
  import org.objectweb.asm.jip.ClassVisitor;
  import org.objectweb.asm.jip.ClassWriter;
  import org.objectweb.asm.jip.Label;
  
  @RunWith(EvoRunner.class) @EvoRunnerParameters(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, separateClassLoader = true) 
  public class ClassReader_Original_ESTest extends ClassReader_Original_ESTest_scaffolding {
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCopyPool() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        ClassWriter arg0 = new ClassWriter((-2102));
        classReader.copyPool(arg0);
        assertEquals(1, ClassWriter.COMPUTE_MAXS);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadUnsignedShortReturningZero() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        classReader.readUnsignedShort(4);
        assertEquals(307, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadUTF8ReturningNonEmptyString() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        char[] arg1 = new char[9];
        String readUTF8 = classReader.readUTF8(399, arg1);
        assertEquals(307, classReader.header);
        assertEquals("\u0000\u0017\u0007", readUTF8);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadUTF8ReturningEmptyString() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        char[] arg1 = new char[1];
        classReader.readUTF8(1193, arg1);
        assertEquals(1537, classReader.getAccess());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadShortReturningPositive() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        short readShort = classReader.readShort(187);
        assertEquals((short)24400, readShort);
        assertEquals(3150, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadLongReturningPositive() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        long readLong = classReader.readLong(2945);
        assertEquals(6197234580549756005L, readLong);
        assertEquals(3150, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadLabel() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        Label[] arg1 = new Label[4];
        Label readLabel = classReader.readLabel(1, arg1);
        assertNotNull(readLabel);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadIntReturningPositive() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        int readInt = classReader.readInt(191);
        assertEquals(1447121989, readInt);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadConstReturningNonNull() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        assertEquals(307, classReader.header);
        
        char[] arg1 = new char[8];
        Object readConst = classReader.readConst(6, arg1);
        assertArrayEquals(new char[] {'n', 'e', 'x', 't', '\u0000', '\u0000', '\u0000', '\u0000'}, arg1);
        assertEquals("next", readConst);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadByteReturningZero() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        int readByte = classReader.readByte(406);
        assertEquals(0, readByte);
        assertEquals(307, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadConst() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        char[] arg1 = new char[9];
        Object readConst = classReader.readConst(7, arg1);
        assertEquals(0, readConst);
        assertEquals(307, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking3ArgumentsWithEmptyArrayAndZero() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        ClassWriter arg0 = new ClassWriter((-2102));
        Attribute[] arg1 = new Attribute[0];
        classReader.accept((ClassVisitor) arg0, arg1, 0);
        assertEquals(1, ClassReader.SKIP_CODE);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking3Arguments0() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.FieldWriter");
        ClassWriter arg0 = new ClassWriter(4);
        classReader.accept((ClassVisitor) arg0, (Attribute[]) null, 4);
        assertEquals(2, ClassReader.SKIP_DEBUG);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadUnsignedShortReturningPositive() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        int readUnsignedShort = classReader.readUnsignedShort(0);
        assertEquals(307, classReader.header);
        assertEquals(51966, readUnsignedShort);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadClassThrowsArrayIndexOutOfBoundsException() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        char[] arg1 = new char[1];
        // Undeclared exception!
        try { 
          classReader.readClass(117, arg1);
          fail("Expecting exception: ArrayIndexOutOfBoundsException");
        
        } catch(ArrayIndexOutOfBoundsException e) {
           //
           // no message in exception (getMessage() returned null)
           //
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadConstThrowsNullPointerException0() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        // Undeclared exception!
        try { 
          classReader.readConst(2, (char[]) null);
          fail("Expecting exception: NullPointerException");
        
        } catch(NullPointerException e) {
           //
           // no message in exception (getMessage() returned null)
           //
           verifyException("org.objectweb.asm.jip.ClassReader", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadUTF8ThrowsArrayIndexOutOfBoundsException() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        char[] arg1 = new char[7];
        // Undeclared exception!
        try { 
          classReader.readUTF8(4, arg1);
          fail("Expecting exception: ArrayIndexOutOfBoundsException");
        
        } catch(ArrayIndexOutOfBoundsException e) {
           //
           // 7
           //
           verifyException("org.objectweb.asm.jip.ClassReader", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadConstThrowsNullPointerException1() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        // Undeclared exception!
        try { 
          classReader.readConst(11, (char[]) null);
          fail("Expecting exception: NullPointerException");
        
        } catch(NullPointerException e) {
           //
           // no message in exception (getMessage() returned null)
           //
           verifyException("org.objectweb.asm.jip.ClassReader", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking2Arguments0() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        ClassWriter arg0 = new ClassWriter(4);
        classReader.accept((ClassVisitor) arg0, 8);
        assertEquals(2, ClassWriter.COMPUTE_FRAMES);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking3Arguments1() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.FieldWriter");
        ClassWriter arg0 = new ClassWriter(4);
        classReader.accept((ClassVisitor) arg0, (Attribute[]) null, 144);
        assertEquals(2, ClassWriter.COMPUTE_FRAMES);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking3ArgumentsWithNegative() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.FieldWriter");
        ClassWriter arg0 = new ClassWriter(4);
        classReader.accept((ClassVisitor) arg0, (Attribute[]) null, (-102));
        assertEquals(1, ClassWriter.COMPUTE_MAXS);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking2Arguments1() throws Throwable  {
        ClassWriter arg0 = new ClassWriter(307);
        ClassReader classReader = new ClassReader("java/lang/Object");
        classReader.accept((ClassVisitor) arg0, 117);
        assertEquals(33, classReader.getAccess());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesClassReaderTaking3Arguments() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        ClassReader arg0 = new ClassReader(classReader.b, 3150, 3150);
        ClassWriter classWriter = null;
        try {
          classWriter = new ClassWriter(arg0, 4180);
          fail("Expecting exception: ArrayIndexOutOfBoundsException");
        
        } catch(ArrayIndexOutOfBoundsException e) {
           //
           // no message in exception (getMessage() returned null)
           //
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetInterfacesReturningNonEmptyArray() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.FieldWriter");
        String[] interfaces = classReader.getInterfaces();
        assertEquals(2022, classReader.header);
        assertEquals(1, interfaces.length);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetInterfacesReturningEmptyArray() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        assertEquals(3150, classReader.header);
        
        String[] interfaces = classReader.getInterfaces();
        assertEquals(0, interfaces.length);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetSuperName() throws Throwable  {
        ClassReader classReader = new ClassReader("java/lang/Class");
        String superName = classReader.getSuperName();
        assertEquals(19569, classReader.header);
        assertEquals("java/lang/Object", superName);
        assertNotNull(superName);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetClassName() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        assertEquals(307, classReader.header);
        
        String className = classReader.getClassName();
        assertEquals("org/objectweb/asm/jip/Edge", className);
        assertNotNull(className);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testAcceptTaking2Arguments2() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.ClassWriter");
        ClassWriter arg0 = new ClassWriter(1);
        classReader.accept((ClassVisitor) arg0, 156);
        assertEquals(8064, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadByteReturningPositive() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        int readByte = classReader.readByte(0);
        assertEquals(202, readByte);
        assertEquals(307, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetItem() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        int item = classReader.getItem(2);
        assertEquals(3150, classReader.header);
        assertEquals(14, item);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadLongReturningNegative() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        long readLong = classReader.readLong(0);
        assertEquals(307, classReader.header);
        assertEquals((-3819410108757049294L), readLong);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAccess() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        int access = classReader.getAccess();
        assertEquals(32, access);
        assertEquals(307, classReader.header);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesClassReaderTakingString() throws Throwable  {
        ClassReader arg0 = new ClassReader("org.objectweb.asm.jip.ClassAdapter");
        ClassWriter classWriter = new ClassWriter(arg0, 726);
        assertEquals(2, ClassWriter.COMPUTE_FRAMES);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadShortReturningNegative() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Opcodes");
        short readShort = classReader.readShort(0);
        assertEquals(3150, classReader.header);
        assertEquals((short) (-13570), readShort);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testReadIntReturningNegative() throws Throwable  {
        ClassReader classReader = new ClassReader("org.objectweb.asm.jip.Edge");
        int readInt = classReader.readInt(2);
        assertEquals(307, classReader.header);
        assertEquals((-1161953280), readInt);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testFailsToCreateClassReaderTakingStringThrowsIOException() throws Throwable  {
        ClassReader classReader = null;
        try {
          classReader = new ClassReader("PkTB<=?}");
          fail("Expecting exception: IOException");
        
        } catch(Throwable e) {
           //
           // Class not found
           //
           verifyException("org.objectweb.asm.jip.ClassReader", e);
        }
    }
  }
  