content: /*
   * This file was automatically generated by UTestGen and EvoSuite
   * Mon Mar 18 10:21:32 GMT 2024
   */
  
  package com.puppycrawl.tools.checkstyle.utils;
  
  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 com.puppycrawl.tools.checkstyle.api.DetailAST;
  import com.puppycrawl.tools.checkstyle.utils.AnnotationUtility;
  import org.evosuite.runtime.EvoRunner;
  import org.evosuite.runtime.EvoRunnerParameters;
  import org.junit.runner.RunWith;
  
  @RunWith(EvoRunner.class) @EvoRunnerParameters(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, separateClassLoader = true) 
  public class AnnotationUtility_Original_ESTest extends AnnotationUtility_Original_ESTest_scaffolding {
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationWithNullAndDetailASTWhereGetTypeIsZero() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        // Undeclared exception!
        try { 
          AnnotationUtility.getAnnotation(arg0, (String) null);
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the annotation is null
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationHolderWithDetailASTWhereGetTypeIsZero() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        DetailAST annotationHolder = AnnotationUtility.getAnnotationHolder(arg0);
        assertNull(annotationHolder);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationThrowsIllegalArgumentException() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        // Undeclared exception!
        try { 
          AnnotationUtility.getAnnotation(arg0, "");
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the annotation is empty or spaces
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationThrowsNullPointerException() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        // Undeclared exception!
        try { 
          AnnotationUtility.getAnnotation(arg0, "!'jF=");
          fail("Expecting exception: NullPointerException");
        
        } catch(NullPointerException e) {
           //
           // no message in exception (getMessage() returned null)
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationWithNullAndEmptyString() throws Throwable  {
        // Undeclared exception!
        try { 
          AnnotationUtility.getAnnotation((DetailAST) null, "");
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the ast is null
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationHolderReturningNull() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        arg0.setType(16);
        DetailAST annotationHolder = AnnotationUtility.getAnnotationHolder(arg0);
        assertNull(annotationHolder);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationHolderWithDetailASTWhereGetColumnIsZero() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        arg0.initialize(155, "");
        DetailAST annotationHolder = AnnotationUtility.getAnnotationHolder(arg0);
        assertNull(annotationHolder);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAnnotationHolderThrowsIllegalArgumentException() throws Throwable  {
        // Undeclared exception!
        try { 
          AnnotationUtility.getAnnotationHolder((DetailAST) null);
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the ast is null
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testContainsAnnotationTakingDetailASTThrowsIllegalArgumentException() throws Throwable  {
        // Undeclared exception!
        try { 
          AnnotationUtility.containsAnnotation((DetailAST) null);
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the ast is null
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testContainsAnnotationTakingDetailAST() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        boolean containsAnnotation = AnnotationUtility.containsAnnotation(arg0);
        assertFalse(containsAnnotation);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testContainsAnnotationTaking2ArgumentsWithNullAndNonEmptyString() throws Throwable  {
        // Undeclared exception!
        try { 
          AnnotationUtility.containsAnnotation((DetailAST) null, "/$]2LIJ?!");
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the ast is null
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testContainsAnnotationTaking2ArgumentsWithNull() throws Throwable  {
        DetailAST arg0 = new DetailAST();
        // Undeclared exception!
        try { 
          AnnotationUtility.containsAnnotation(arg0, (String) null);
          fail("Expecting exception: IllegalArgumentException");
        
        } catch(IllegalArgumentException e) {
           //
           // the annotation is null
           //
           verifyException("com.puppycrawl.tools.checkstyle.utils.AnnotationUtility", e);
        }
    }
  }
  