/*
 * Arrebol Consultancy copyright.
 * 
 * This code belongs to Arrebol Consultancy
 * its use, redistribution or modification are prohibited 
 * without written authorization from Arrebol Consultancy.
 */
package com.arrebol.taxiservicios.controller.admin;

import java.math.BigDecimal;
import java.util.Calendar;
import java.util.Date;
import org.junit.Assert;
import org.junit.Test;
import org.junit.Before;

/**
 *
 * @author Carlos Janitzio Zavala Lopez <janitzio.zavala@arrebol.com.mx>
 */
public class StableSmallBoxControllerTest {

    private StableSmallBoxController controller;
    private Date date;

    @Before
    public void setUp() {
        controller = new StableSmallBoxController();
        Calendar dateToFind = Calendar.getInstance();

        //2019-03-07 21:07:04
        dateToFind.set(2022, 05, 23, 9, 7, 4);
        date = dateToFind.getTime();
    }

    public StableSmallBoxControllerTest() {
    }

    //@Test
    public void getTotalInBox() {
        try {
            BigDecimal total = controller.getTotalInBox("");

            System.out.println("Total in general box = " + total);
        } catch (Exception e) {
            e.printStackTrace();
        }
    }

    //@Test
    public void existStableGeneralBoxByCreatedOn() {
        try {
            Assert.assertTrue(controller.existStableGeneralBoxByCreatedOn(new Date(), ""));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }

    //@Test
    public void existNextPaidStableSmallBoxByCreatedOn() {
        try {
            Assert.assertTrue(controller.existNextPaidStableSmallBoxByCreatedOn(date, ""));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }

    @Test
    public void isReadyToDoADailyCash() {
        try {
            Assert.assertTrue(controller.isReadyToDoADailyCash(""));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }

}
