content: /*
   * This file was automatically generated by EvoSuite
   */
  
  package com.lts.caloriecount.data.frequent;
  
  import org.junit.Test;
  import org.junit.runner.RunWith;
  import org.evosuite.junit.EvoSuiteRunner;
  import static org.junit.Assert.*;
  import com.lts.application.ApplicationException;
  import com.lts.caloriecount.app.CalorieCountException;
  import com.lts.caloriecount.data.food.Food;
  import com.lts.caloriecount.data.frequent.FrequentFood;
  import com.lts.caloriecount.data.frequent.FrequentFoodList;
  import com.lts.caloriecount.data.meal.Meal;
  import com.lts.xml.simple.SimpleElement;
  import java.util.Collection;
  import java.util.List;
  import org.junit.BeforeClass;
  
  @RunWith(EvoSuiteRunner.class)
  public class FrequentFoodListEvoSuiteTest {
  
    @BeforeClass 
    public static void initEvoSuiteFramework(){ 
      org.evosuite.Properties.REPLACE_CALLS = true; 
    } 
  
  
    @Test
    public void test0()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Meal meal0 = new Meal();
        SimpleElement simpleElement0 = meal0.createSerializationElement();
        frequentFoodList0.deserializeFrom(simpleElement0);
        frequentFoodList0.postDeserialize();
        assertEquals(false, frequentFoodList0.isEmpty());
        assertEquals(1, frequentFoodList0.size());
    }
  
    @Test
    public void test1()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        String string0 = frequentFoodList0.getSerializationElementName();
        assertEquals("frequentFoods", string0);
    }
  
    @Test
    public void test2()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Food food0 = new Food(0);
        frequentFoodList0.createFrequentFood(food0);
        assertEquals(true, frequentFoodList0.isDirty());
        assertEquals(false, frequentFoodList0.isEmpty());
    }
  
    @Test
    public void test3()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        frequentFoodList0.setFrequentFoods((List<FrequentFood>) frequentFoodList0);
        assertEquals(true, frequentFoodList0.isEmpty());
    }
  
    @Test
    public void test4()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Food food0 = new Food((-1890), "Sr5/@=l", (-1890), "Sr5/@=l");
        FrequentFood frequentFood0 = frequentFoodList0.findOrCreate(food0);
        // Undeclared exception!
        try {
          frequentFoodList0.add((-1890), frequentFood0);
          fail("Expecting exception: RuntimeException");
        } catch(RuntimeException e) {
          /*
           * Duplicate food ID: Sr5/@=l,-1890
           */
        }
    }
  
    @Test
    public void test5()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        // Undeclared exception!
        try {
          frequentFoodList0.increment((Food) null);
          fail("Expecting exception: NullPointerException");
        } catch(NullPointerException e) {
        }
    }
  
    @Test
    public void test6()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Food food0 = new Food();
        frequentFoodList0.findOrCreate(food0);
        frequentFoodList0.removeEntry(0);
        assertEquals(true, frequentFoodList0.isDirty());
        assertEquals(true, frequentFoodList0.isEmpty());
    }
  
    @Test
    public void test7()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        try {
          frequentFoodList0.removeEntry((-1382));
          fail("Expecting exception: CalorieCountException");
        } catch(CalorieCountException e) {
          /*
           * FrequentFoodNotFound
           */
        }
    }
  
    @Test
    public void test8()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Food food0 = new Food();
        frequentFoodList0.findOrCreate(food0);
        frequentFoodList0.postDeserialize();
        assertEquals(1, frequentFoodList0.size());
        assertEquals(false, frequentFoodList0.isEmpty());
    }
  
    @Test
    public void test9()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Meal meal0 = new Meal();
        SimpleElement simpleElement0 = meal0.createSerializationElement();
        frequentFoodList0.deserializeFrom(simpleElement0);
        // Undeclared exception!
        try {
          frequentFoodList0.addAll((Collection<? extends FrequentFood>) frequentFoodList0);
          fail("Expecting exception: RuntimeException");
        } catch(RuntimeException e) {
          /*
           * Duplicate food ID: -1
           */
        }
    }
  
    @Test
    public void test10()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Meal meal0 = new Meal();
        SimpleElement simpleElement0 = meal0.createSerializationElement();
        frequentFoodList0.deserializeFrom(simpleElement0);
        frequentFoodList0.resetAllCounts();
        assertEquals(3, frequentFoodList0.size());
    }
  
    @Test
    public void test11()  throws Throwable  {
        FrequentFoodList frequentFoodList0 = new FrequentFoodList();
        Food food0 = new Food();
        FrequentFood frequentFood0 = frequentFoodList0.findOrCreate(food0);
        FrequentFood frequentFood1 = frequentFoodList0.findOrCreate(food0);
        assertEquals(true, frequentFoodList0.isDirty());
        assertSame(frequentFood1, frequentFood0);
    }
  }
  