content: /*
   * This file was automatically generated by UTestGen and EvoSuite
   * Thu Mar 21 07:53:41 GMT 2024
   */
  
  package wheel.asm;
  
  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 org.evosuite.runtime.EvoRunner;
  import org.evosuite.runtime.EvoRunnerParameters;
  import org.junit.runner.RunWith;
  import wheel.asm.ClassWriter;
  import wheel.asm.FieldWriter;
  
  @RunWith(EvoRunner.class) @EvoRunnerParameters(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, separateClassLoader = true) 
  public class FieldWriter_ESTest extends FieldWriter_ESTest_scaffolding {
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetSizeReturningPositive() throws Throwable  {
        // Given a FieldWriter instance with a version of -953 and no data
        ClassWriter classWriter = new ClassWriter(91);
        classWriter.version = (-953);
        FieldWriter fieldWriter = new FieldWriter(classWriter, (-953), "", "", "", (Object) null);
        
        // When the getSize method is called
        int size = fieldWriter.getSize();
        
        // Then the returned size should be 22
        assertEquals(22, size);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesFieldWriter0() throws Throwable  {
        // No Comments were added
        ClassWriter arg0 = new ClassWriter(4042);
        FieldWriter fieldWriter = new FieldWriter(arg0, 4042, "}", "}", "}", "}");
        int size = fieldWriter.getSize();
        assertEquals(24, size);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesFieldWriter1() throws Throwable  {
        // rollbacked to evosuite
        ClassWriter arg0 = new ClassWriter(91);
        FieldWriter fieldWriter = new FieldWriter(arg0, (-953), "", "", "", (Object) null);
        int size = fieldWriter.getSize();
        assertEquals(28, size);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testVisitAnnotationWithFalse() throws Throwable  {
        // Test that the FieldWriter class correctly calculates the size of a field
        ClassWriter arg0 = new ClassWriter(91);
        FieldWriter fieldWriter = new FieldWriter(arg0, 1, "}", "}", "}", "}");
        fieldWriter.visitAnnotation("}", false);
        int expectedSize = 36;
        int actualSize = fieldWriter.getSize();
        assertEquals(expectedSize, actualSize);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testVisitAnnotationWithTrue() throws Throwable  {
        // rollbacked to evosuite
        ClassWriter arg0 = new ClassWriter(91);
        FieldWriter fieldWriter = new FieldWriter(arg0, (-953), "", "", "", (Object) null);
        fieldWriter.visitAnnotation("_&V\"jD4i1c%'", true);
        int size = fieldWriter.getSize();
        assertEquals(40, size);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesFieldWriter2() throws Throwable  {
        // rollbacked to evosuite
        ClassWriter arg0 = new ClassWriter(644);
        FieldWriter fieldWriter = new FieldWriter(arg0, 1, "", "", (String) null, "");
        int size = fieldWriter.getSize();
        assertEquals(16, size);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testFailsToCreateFieldWriterThrowsIllegalArgumentException() throws Throwable  {
        // No Comments were added
        ClassWriter arg5 = new ClassWriter(91);
        arg5.visitField(91, "", "", "", "");
        FieldWriter fieldWriter = null;
        try {
          fieldWriter = new FieldWriter(arg5, 1, "", "", "", arg5);
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // value wheel.asm.ClassWriter@5
           //
           verifyException("wheel.asm.ClassWriter", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testVisitEnd() throws Throwable  {
        // rollbacked to evosuite
        ClassWriter arg0 = new ClassWriter(2062);
        FieldWriter fieldWriter = new FieldWriter(arg0, 2062, "96Nz4a*,;oHiNu/*", "96Nz4a*,;oHiNu/*", "", "");
        fieldWriter.visitEnd();
    }
  }
  