content: /*
   * This file was automatically generated by UTestGen and EvoSuite
   * Mon Mar 18 04:39:16 GMT 2024
   */
  
  package bierse.model;
  
  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 bierse.model.Drink;
  import bierse.model.Model;
  import bierse.model.Settings;
  import java.io.File;
  import org.evosuite.runtime.EvoRunner;
  import org.evosuite.runtime.EvoRunnerParameters;
  import org.evosuite.runtime.System;
  import org.evosuite.runtime.testdata.FileSystemHandling;
  import org.junit.runner.RunWith;
  
  @RunWith(EvoRunner.class) @EvoRunnerParameters(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, separateClassLoader = true) 
  public class Drink_Original_ESTest extends Drink_Original_ESTest_scaffolding {
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSaveThrowsTooManyResourcesException() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("y)q.J+'", arg1, 32);
        FileSystemHandling.shouldAllThrowIOExceptions();
        // Undeclared exception!
        drink.save();
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testToStringReturningNull() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink((String) null, arg1, 1621);
        String string = drink.toString();
        assertEquals(0, drink.getTrend());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(100, drink.getStartPrice());
        assertEquals(112, drink.getKey());
        assertNull(string);
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTotalSold());
        assertEquals(1621, drink.getCurrentPrice());
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getLastSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testToStringReturningNonEmptyString() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("xOa&E5", arg1);
        String string = drink.toString();
        assertEquals(112, drink.getKey());
        assertEquals(70, drink.getMinPrice());
        assertEquals("xOa&E5", string);
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getTotalSold());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTrend());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSaveReturningFileWhereLastModifiedIsNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("`XB", arg1);
        System.setCurrentTimeMillis((-4636L));
        File save = drink.save();
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(244L, save.length());
        assertEquals(0, drink.getDirectPrice());
        assertFalse(save.isHidden());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(112, drink.getKey());
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTotalSold());
        assertNotNull(save);
        assertEquals(0, drink.getLastSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetCurrentPrice() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1);
        drink.setMinPrice((-1227133513));
        drink.setCurrentPrice(20);
        int recalculate = drink.recalculate();
        assertEquals((-1), drink.getTrend());
        assertEquals(0, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testIsUsedReturningFalse() throws Throwable  {
        Model arg1 = new Model();
        Drink arg0 = new Drink(":6", arg1);
        assertTrue(arg0.isUsed());
        
        arg1.disableDrink(arg0);
        boolean used = arg0.isUsed();
        assertFalse(used);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testIsKeepPriceReturningTrue() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("xOa&E5", arg1);
        assertFalse(drink.isKeepPrice());
        
        drink.setKeepPrice(true);
        boolean keepPrice = drink.isKeepPrice();
        assertTrue(keepPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTrendReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("To@cy", arg1, 8);
        drink.recalculate();
        int trend = drink.getTrend();
        assertEquals(70, drink.getCurrentPrice());
        assertEquals(1, trend);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTrendReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1);
        drink.recalculate();
        int trend = drink.getTrend();
        assertEquals((-1), trend);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTotalSoldReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("xOa&E5", arg1);
        drink.setTotalSold(8);
        int totalSold = drink.getTotalSold();
        assertEquals(8, totalSold);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetNameReturningNull() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink((String) null, arg1, 16);
        String name = drink.getName();
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0, drink.getTotalSold());
        assertEquals(70, drink.getMinPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(112, drink.getKey());
        assertEquals(16, drink.getCurrentPrice());
        assertEquals(100, drink.getStartPrice());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getTrend());
        assertTrue(drink.isUsed());
        assertNull(name);
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetNameReturningNonEmptyString() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1);
        String name = drink.getName();
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(70, drink.getMinPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", name);
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(112, drink.getKey());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTrend());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMinPriceReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1);
        assertEquals(70, drink.getMinPrice());
        
        drink.setMinPrice(0);
        int minPrice = drink.getMinPrice();
        assertEquals(0, minPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMinPriceReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("z0", arg1);
        drink.setMinPrice((-1500));
        int minPrice = drink.getMinPrice();
        assertEquals((-1500), minPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMaxStepReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("F3Q~0i", arg1, (-611));
        assertEquals(20, drink.getMaxStep());
        
        drink.setMaxStep(0);
        int maxStep = drink.getMaxStep();
        assertEquals(0, maxStep);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMaxStepReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1, 313);
        drink.setMaxStep((-1885497974));
        int maxStep = drink.getMaxStep();
        assertEquals((-1885497974), maxStep);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetLastSoldReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink((String) null, arg1, (-1912169796));
        drink.sell((-1912169796));
        int lastSold = drink.getLastSold();
        assertEquals((-1912169796), lastSold);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDirectPriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1);
        drink.setDirectPrice(4);
        int directPrice = drink.getDirectPrice();
        assertEquals(4, directPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDirectPriceReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("6", arg1);
        drink.setDirectPrice((-1122));
        int directPrice = drink.getDirectPrice();
        assertEquals((-1122), directPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDeltaAmountReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("", arg1, 1);
        assertEquals(15, drink.getDeltaAmount());
        
        drink.setDeltaAmount(0);
        int deltaAmount = drink.getDeltaAmount();
        assertEquals(0, deltaAmount);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetCurrentPriceReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1, 0);
        int currentPrice = drink.getCurrentPrice();
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, currentPrice);
        assertEquals("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", drink.getName());
        assertEquals(20, drink.getMaxStep());
        assertTrue(drink.isUsed());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getDirectPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetCurrentPriceReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("2#9+Z", arg1, (-921));
        int currentPrice = drink.getCurrentPrice();
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTrend());
        assertEquals(0, drink.getDirectPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(70, drink.getMinPrice());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals((-921), currentPrice);
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getTotalSold());
        assertEquals("2#9+Z", drink.toString());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getLastSold());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertTrue(drink.isUsed());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAverageSoldPriceReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1);
        drink.setAverageSoldPrice((-2310.89F));
        float averageSoldPrice = drink.getAverageSoldPrice();
        assertEquals((-2310.89F), averageSoldPrice, 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAveragePriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1, 16);
        drink.recalculate();
        float averagePrice = drink.getAveragePrice();
        assertEquals(70, drink.getCurrentPrice());
        assertEquals(16.0F, averagePrice, 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAveragePriceReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1, (-2776));
        drink.recalculate();
        float averagePrice = drink.getAveragePrice();
        assertEquals((-2776.0F), averagePrice, 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAverageAmountReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        arg1.setIteration((-1986));
        Drink drink = new Drink("Average price: ", arg1, 8);
        drink.sell(16);
        drink.recalculate();
        float averageAmount = drink.getAverageAmount();
        assertEquals((-0.0040281974F), drink.getAveragePrice(), 0.01F);
        assertEquals((-0.008056395F), averageAmount, 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testLoad() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("=Q@~[x1M_", arg1, 32);
        drink.load();
        assertEquals(0, drink.getTrend());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals("=Q@~[x1M_", drink.toString());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals(70, drink.getMinPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(20, drink.getMaxStep());
        assertEquals(112, drink.getKey());
        assertEquals(32, drink.getCurrentPrice());
        assertEquals(100, drink.getStartPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesDrinkTaking3ArgumentsAndEqualsAndEqualsReturningFalse0() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("", arg1, (-3234));
        Drink arg0 = new Drink((String) null, arg1, 1773);
        boolean equals = drink.equals(arg0);
        assertEquals(15, arg0.getDeltaAmount());
        assertEquals(0, arg0.getTrend());
        assertEquals(0, arg0.getDirectPrice());
        assertEquals(1773, arg0.getCurrentPrice());
        assertEquals(0.0F, arg0.getAveragePrice(), 0.01F);
        assertFalse(arg0.isKeepPrice());
        assertEquals(20, arg0.getMaxStep());
        assertEquals(112, arg0.getKey());
        assertEquals(70, arg0.getMinPrice());
        assertEquals(100, arg0.getStartPrice());
        assertEquals(20, arg0.getTargetAmount());
        assertEquals(0, arg0.getTotalSold());
        assertEquals(0.0F, arg0.getAverageSoldPrice(), 0.01F);
        assertFalse(equals);
        assertEquals("", drink.getName());
        assertEquals(0, arg0.getLastSold());
        assertTrue(arg0.isUsed());
        assertEquals(0.0F, arg0.getAverageAmount(), 0.01F);
        assertEquals(130, arg0.getMaxPrice());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesDrinkTaking3ArgumentsAndEqualsAndEqualsReturningFalse1() throws Throwable  {
        Model arg1 = new Model();
        Drink arg0 = new Drink("./conf/", arg1, 8);
        Drink drink = new Drink((String) null, arg1, 4);
        boolean equals = drink.equals(arg0);
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertFalse(arg0.equals((Object)drink));
        assertEquals(4, drink.getCurrentPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0, drink.getLastSold());
        assertFalse(equals);
        assertEquals(0, drink.getDirectPrice());
        assertTrue(drink.isUsed());
        assertEquals("./conf/", arg0.getName());
        assertEquals(0, drink.getTrend());
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(100, drink.getStartPrice());
        assertEquals(112, drink.getKey());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesDrinkTaking3ArgumentsAndEqualsAndEqualsReturningTrue0() throws Throwable  {
        Model arg1 = new Model();
        Drink arg0 = new Drink((String) null, arg1, 587);
        boolean equals = arg0.equals(arg0);
        assertEquals(0.0F, arg0.getAverageSoldPrice(), 0.01F);
        assertTrue(equals);
        assertEquals(587, arg0.getCurrentPrice());
        assertEquals(0, arg0.getDirectPrice());
        assertEquals(0, arg0.getTrend());
        assertEquals(100, arg0.getStartPrice());
        assertEquals(112, arg0.getKey());
        assertEquals(70, arg0.getMinPrice());
        assertEquals(20, arg0.getTargetAmount());
        assertEquals(20, arg0.getMaxStep());
        assertFalse(arg0.isKeepPrice());
        assertEquals(0, arg0.getTotalSold());
        assertEquals(0.0F, arg0.getAverageAmount(), 0.01F);
        assertEquals(0.0F, arg0.getAveragePrice(), 0.01F);
        assertEquals(15, arg0.getDeltaAmount());
        assertEquals(130, arg0.getMaxPrice());
        assertTrue(arg0.isUsed());
        assertEquals(0, arg0.getLastSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesDrinkTaking3ArgumentsAndEqualsAndEqualsReturningTrue1() throws Throwable  {
        Model arg1 = new Model();
        Drink arg0 = new Drink("", arg1, (-3234));
        boolean equals = arg0.equals(arg0);
        assertFalse(arg0.isKeepPrice());
        assertEquals(0, arg0.getTotalSold());
        assertEquals(20, arg0.getTargetAmount());
        assertEquals((-3234), arg0.getCurrentPrice());
        assertEquals(20, arg0.getMaxStep());
        assertEquals(112, arg0.getKey());
        assertEquals(100, arg0.getStartPrice());
        assertEquals(0.0F, arg0.getAverageAmount(), 0.01F);
        assertEquals(0, arg0.getTrend());
        assertEquals(0, arg0.getDirectPrice());
        assertTrue(arg0.isUsed());
        assertEquals(130, arg0.getMaxPrice());
        assertEquals(0.0F, arg0.getAverageSoldPrice(), 0.01F);
        assertTrue(equals);
        assertEquals("", arg0.toString());
        assertEquals(0, arg0.getLastSold());
        assertEquals(70, arg0.getMinPrice());
        assertEquals(15, arg0.getDeltaAmount());
        assertEquals(0.0F, arg0.getAveragePrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testLoadThrowsTooManyResourcesException() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("=Q@~[x1M_", arg1, 32);
        drink.save();
        // Undeclared exception!
        drink.load();
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSave() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("=<F5 *h", arg1);
        drink.save();
        File save = drink.save();
        assertNotNull(save);
        assertEquals(70, drink.getMinPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0, drink.getLastSold());
        assertEquals(112, drink.getKey());
        assertEquals(20, drink.getTargetAmount());
        assertFalse(drink.isKeepPrice());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertFalse(save.isHidden());
        assertEquals(244L, save.length());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSaveReturningNull() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("Neues Getr\u00E4nk", arg1, 2);
        File save = drink.save();
        assertEquals(0, drink.getDirectPrice());
        assertNull(save);
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getLastSold());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0, drink.getTotalSold());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(2, drink.getCurrentPrice());
        assertEquals(70, drink.getMinPrice());
        assertFalse(drink.isKeepPrice());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesDrinkTaking3ArgumentsAndCallsRecalculate() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1, 313);
        int recalculate = drink.recalculate();
        assertEquals((-1), drink.getTrend());
        assertEquals(130, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testRecalculate0() throws Throwable  {
        Model arg1 = new Model();
        Settings settings = arg1.getSettings();
        settings.setStandardLogic(false);
        Drink drink = new Drink("./conf/settings/", arg1);
        drink.setLastSold(3713);
        int recalculate = drink.recalculate();
        assertEquals((-1), drink.getTrend());
        assertEquals(80, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testCreatesDrinkTaking2ArgumentsAndCallsRecalculate() throws Throwable  {
        Model arg1 = new Model();
        Settings settings = arg1.getSettings();
        settings.setStandardLogic(false);
        Drink drink = new Drink("./conf/settings/", arg1);
        int recalculate = drink.recalculate();
        assertEquals(1, drink.getTrend());
        assertEquals(120, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testRecalculate1() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/settings/", arg1);
        drink.setLastSold(3713);
        int recalculate = drink.recalculate();
        assertEquals(3713.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(120, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDeltaAmountReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("#qt18}9+L]/(", arg1);
        int deltaAmount = drink.getDeltaAmount();
        assertEquals(70, drink.getMinPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals(15, deltaAmount);
        assertEquals(20, drink.getTargetAmount());
        assertEquals("#qt18}9+L]/(", drink.toString());
        assertEquals(112, drink.getKey());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getTotalSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAverageSoldPriceReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1);
        float averageSoldPrice = drink.getAverageSoldPrice();
        assertEquals(70, drink.getMinPrice());
        assertEquals(112, drink.getKey());
        assertEquals(0.0F, averageSoldPrice, 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0, drink.getLastSold());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertFalse(drink.isKeepPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(100, drink.getCurrentPrice());
        assertTrue(drink.isUsed());
        assertEquals("./data/", drink.toString());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTrend());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testToStringReturningEmptyString() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("", arg1, 32);
        String string = drink.toString();
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals("", string);
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getLastSold());
        assertEquals(32, drink.getCurrentPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(70, drink.getMinPrice());
        assertFalse(drink.isKeepPrice());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetKey() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1);
        drink.setKey((-1227133513));
        int key = drink.getKey();
        assertEquals((-1227133513), key);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetLastSoldReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("+NG'+02f]8", arg1);
        drink.setLastSold(32);
        int lastSold = drink.getLastSold();
        assertEquals(32, lastSold);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetAveragePrice() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1);
        drink.setAveragePrice(32);
        assertEquals(32.0F, drink.getAveragePrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetLastSoldReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1);
        int lastSold = drink.getLastSold();
        assertEquals(0, lastSold);
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(70, drink.getMinPrice());
        assertTrue(drink.isUsed());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(20, drink.getTargetAmount());
        assertEquals("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", drink.toString());
        assertEquals(112, drink.getKey());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAverageSoldPriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1);
        drink.setAverageSoldPrice(2769.4924F);
        float averageSoldPrice = drink.getAverageSoldPrice();
        assertEquals(2769.4924F, averageSoldPrice, 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testRecalculateReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1, (-353));
        drink.setMinPrice((-337));
        int recalculate = drink.recalculate();
        assertEquals(1, drink.getTrend());
        assertEquals((-337), recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetAverageAmount() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1);
        drink.setAverageAmount(2);
        float averageAmount = drink.getAverageAmount();
        assertEquals(2.0F, averageAmount, 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMaxPriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("F3Q~0i", arg1, (-611));
        int maxPrice = drink.getMaxPrice();
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertFalse(drink.isKeepPrice());
        assertEquals(130, maxPrice);
        assertEquals(15, drink.getDeltaAmount());
        assertEquals("F3Q~0i", drink.toString());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(70, drink.getMinPrice());
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getTrend());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals((-611), drink.getCurrentPrice());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetMaxStep() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1, 313);
        drink.setMaxStep((-1885497974));
        drink.recalculate();
        int recalculate = drink.recalculate();
        assertEquals(0, drink.getTrend());
        assertEquals(130, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetKeepPrice() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink(";", arg1, 8);
        drink.setKeepPrice(true);
        int recalculate = drink.recalculate();
        assertEquals(8.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(70, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetNameReturningEmptyString() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("", arg1);
        String name = drink.getName();
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0, drink.getLastSold());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(70, drink.getMinPrice());
        assertEquals(112, drink.getKey());
        assertEquals(0, drink.getTrend());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals("", name);
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertFalse(drink.isKeepPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTotalSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMaxStepReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("F3Q~0i", arg1, (-611));
        int maxStep = drink.getMaxStep();
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(20, maxStep);
        assertEquals(0, drink.getLastSold());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals("F3Q~0i", drink.getName());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals((-611), drink.getCurrentPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals(100, drink.getStartPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(112, drink.getKey());
        assertEquals(70, drink.getMinPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetMinPriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1);
        int minPrice = drink.getMinPrice();
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertFalse(drink.isKeepPrice());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(112, drink.getKey());
        assertEquals(20, drink.getMaxStep());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(70, minPrice);
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(0, drink.getTrend());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getTotalSold());
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getLastSold());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", drink.getName());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testIsKeepPriceReturningFalse() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("xOa&E5", arg1);
        boolean keepPrice = drink.isKeepPrice();
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertFalse(keepPrice);
        assertEquals(0, drink.getTotalSold());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals("xOa&E5", drink.toString());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(112, drink.getKey());
        assertEquals(70, drink.getMinPrice());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getTrend());
        assertEquals(0, drink.getLastSold());
        assertEquals(15, drink.getDeltaAmount());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTotalSoldReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("=<F5 *h", arg1);
        int totalSold = drink.getTotalSold();
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(0, drink.getTrend());
        assertEquals(15, drink.getDeltaAmount());
        assertTrue(drink.isUsed());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, totalSold);
        assertEquals(0, drink.getLastSold());
        assertEquals(112, drink.getKey());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(70, drink.getMinPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals("=<F5 *h", drink.toString());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetStartPrice() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("-KM!Acwuj><DDUH", arg1, 535);
        drink.setStartPrice((-1749));
        int startPrice = drink.getStartPrice();
        assertEquals((-1749), startPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetDirectPrice() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink(";", arg1, 1);
        drink.setDirectPrice(32);
        int recalculate = drink.recalculate();
        assertEquals(70, drink.getCurrentPrice());
        assertEquals(70, recalculate);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAverageAmountReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("+NG'+02f]8", arg1);
        float averageAmount = drink.getAverageAmount();
        assertEquals(0, drink.getLastSold());
        assertEquals(70, drink.getMinPrice());
        assertEquals("+NG'+02f]8", drink.toString());
        assertEquals(20, drink.getMaxStep());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0, drink.getTrend());
        assertEquals(112, drink.getKey());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0.0F, averageAmount, 0.01F);
        assertFalse(drink.isKeepPrice());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTotalSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetTargetAmount() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", arg1);
        assertEquals(20, drink.getTargetAmount());
        
        drink.setTargetAmount((-1));
        int targetAmount = drink.getTargetAmount();
        assertEquals((-1), targetAmount);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetStartPriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1, 313);
        int startPrice = drink.getStartPrice();
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(70, drink.getMinPrice());
        assertEquals(112, drink.getKey());
        assertEquals(0, drink.getTrend());
        assertEquals(313, drink.getCurrentPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals("./conf/", drink.getName());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getLastSold());
        assertTrue(drink.isUsed());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0, drink.getTotalSold());
        assertEquals(100, startPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDeltaAmountReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("#qt18}9+L]/(", arg1);
        drink.setDeltaAmount((-1982523751));
        int deltaAmount = drink.getDeltaAmount();
        assertEquals((-1982523751), deltaAmount);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTotalSoldReturningNegative() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("=<F5 *h", arg1);
        drink.setTotalSold((-16));
        int totalSold = drink.getTotalSold();
        assertEquals((-16), totalSold);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDirectPriceReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1);
        int directPrice = drink.getDirectPrice();
        assertEquals(0, drink.getTrend());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(100, drink.getCurrentPrice());
        assertTrue(drink.isUsed());
        assertEquals(130, drink.getMaxPrice());
        assertEquals("./conf/", drink.toString());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getTotalSold());
        assertEquals(112, drink.getKey());
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(0, directPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetMaxPrice() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink((String) null, arg1, 1621);
        drink.setMaxPrice((-2048));
        int maxPrice = drink.getMaxPrice();
        assertEquals((-2048), maxPrice);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDataHeaderString() throws Throwable  {
        String dataHeaderString = Drink.getDataHeaderString();
        assertEquals("NAME;MIN_PRICE;START_PRICE;MAX_PRICE;AVG_AMOUNT;AVG_PRICE;AVG_SOLD_PRICE;TOTAL_SOLD", dataHeaderString);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetUsed() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("xOa&E5", arg1);
        drink.setUsed(true);
        assertTrue(drink.isUsed());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals("xOa&E5", drink.getName());
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getTrend());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTotalSold());
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(70, drink.getMinPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetDataString() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("F3Q~0i", arg1, (-611));
        String dataString = drink.getDataString();
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(112, drink.getKey());
        assertEquals(0, drink.getTrend());
        assertEquals(0, drink.getDirectPrice());
        assertEquals("F3Q~0i;70;100;130;0.0;0.0;0.0;0", dataString);
        assertEquals(20, drink.getMaxStep());
        assertEquals((-611), drink.getCurrentPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(0, drink.getLastSold());
        assertFalse(drink.isKeepPrice());
        assertTrue(drink.isUsed());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetKeyReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("F3Q~0i", arg1, (-611));
        int key = drink.getKey();
        assertEquals(0, drink.getTrend());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals(15, drink.getDeltaAmount());
        assertFalse(drink.isKeepPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals("F3Q~0i", drink.toString());
        assertEquals(70, drink.getMinPrice());
        assertEquals(0, drink.getTotalSold());
        assertEquals((-611), drink.getCurrentPrice());
        assertEquals(100, drink.getStartPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(112, key);
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testIsUsedReturningTrue() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink(":6", arg1);
        boolean used = drink.isUsed();
        assertEquals(0, drink.getLastSold());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(112, drink.getKey());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertTrue(used);
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(":6", drink.toString());
        assertEquals(0, drink.getTotalSold());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals(100, drink.getCurrentPrice());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetAveragePriceReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./data/", arg1, (-2776));
        float averagePrice = drink.getAveragePrice();
        assertEquals(20, drink.getMaxStep());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals(70, drink.getMinPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getTrend());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(0.0F, averagePrice, 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(130, drink.getMaxPrice());
        assertTrue(drink.isUsed());
        assertEquals((-2776), drink.getCurrentPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals("./data/", drink.getName());
        assertEquals(0, drink.getTotalSold());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testSetName() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("xOa&E5", arg1);
        drink.setName("./data/");
        drink.save();
        assertEquals("./data/", drink.toString());
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetCurrentPriceReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("=<F5 *h", arg1);
        int currentPrice = drink.getCurrentPrice();
        assertEquals(0, drink.getLastSold());
        assertEquals(70, drink.getMinPrice());
        assertEquals(20, drink.getTargetAmount());
        assertEquals(112, drink.getKey());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getTotalSold());
        assertEquals(0, drink.getDirectPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals("=<F5 *h", drink.toString());
        assertEquals(100, currentPrice);
        assertEquals(20, drink.getMaxStep());
        assertEquals(15, drink.getDeltaAmount());
        assertTrue(drink.isUsed());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getTrend());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTargetAmountReturningPositive() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("F3Q~0i", arg1, (-611));
        int targetAmount = drink.getTargetAmount();
        assertEquals(0, drink.getTotalSold());
        assertEquals((-611), drink.getCurrentPrice());
        assertFalse(drink.isKeepPrice());
        assertEquals(20, drink.getMaxStep());
        assertEquals(112, drink.getKey());
        assertEquals(100, drink.getStartPrice());
        assertEquals(20, targetAmount);
        assertEquals(70, drink.getMinPrice());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals("F3Q~0i", drink.toString());
        assertTrue(drink.isUsed());
        assertEquals(130, drink.getMaxPrice());
        assertEquals(0, drink.getDirectPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getTrend());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
    }
  
    @Test
    @Timeout(value = 4000 , unit = TimeUnit.MILLISECONDS)
    public void testGetTrendReturningZero() throws Throwable  {
        Model arg1 = new Model();
        Drink drink = new Drink("./conf/", arg1);
        int trend = drink.getTrend();
        assertEquals(0.0F, drink.getAverageSoldPrice(), 0.01F);
        assertEquals(70, drink.getMinPrice());
        assertEquals(112, drink.getKey());
        assertEquals(0, trend);
        assertEquals(0, drink.getLastSold());
        assertEquals(0, drink.getTotalSold());
        assertEquals(0.0F, drink.getAveragePrice(), 0.01F);
        assertEquals(0, drink.getDirectPrice());
        assertEquals(100, drink.getCurrentPrice());
        assertEquals(15, drink.getDeltaAmount());
        assertEquals(20, drink.getMaxStep());
        assertFalse(drink.isKeepPrice());
        assertEquals(0.0F, drink.getAverageAmount(), 0.01F);
        assertEquals(20, drink.getTargetAmount());
        assertEquals(130, drink.getMaxPrice());
        assertEquals("./conf/", drink.getName());
        assertTrue(drink.isUsed());
    }
  }
  