Package test.org.magicbox.dbunit

Examples of test.org.magicbox.dbunit.DBCentri.preparaDb()


 
  @SuppressWarnings("unchecked")
  public void testElenco() throws Exception {

    DBCentri dbCentro = new DBCentri();
    dbCentro.preparaDb();

    _reqMock = new MockHttpServletRequest("GET", "/centri.admin?action=elenco");

    ModelAndView mav = _controller.elenco(_reqMock, _resMock);
    assertEquals("admin/elencoCentri", mav.getViewName());
View Full Code Here


  }
 
  public void testDettaglio() throws Exception {

    DBCentri dbCentro = new DBCentri();
    dbCentro.preparaDb();

    _reqMock = new MockHttpServletRequest("GET", "/centri.admin?action=dettaglio");
    _reqMock.setParameter(Constant.ID, "46");
    ModelAndView mav = _controller.dettaglio(_reqMock, _resMock);
    assertEquals("admin/dettaglioCentro", mav.getViewName());
View Full Code Here

 
 
  public void testConferma() throws Exception {

    DBCentri dbCentro = new DBCentri();
    dbCentro.preparaDb();

    _reqMock = new MockHttpServletRequest("GET", "/centri.admin?action=conferma");
    _reqMock.setParameter(Constant.ID, "46");
    ModelAndView mav = _controller.conferma(_reqMock, _resMock);
    assertEquals("admin/confermaEliminazioneCentro", mav.getViewName());
View Full Code Here

  }
 
  public void testElimina() throws Exception {

    DBCentri dbCentro = new DBCentri();
    dbCentro.preparaDb();

    _reqMock = new MockHttpServletRequest("GET", "/centri.admin?action=elimina");
    _reqMock.setParameter(Constant.ID, "46");
    ModelAndView mav = _controller.elimina(_reqMock, _resMock);
    assertEquals(Constant.REDIRECT_ELENCO_CENTRI, mav.getViewName());
View Full Code Here

  @SuppressWarnings("unchecked")
  public void testElenco() throws Exception {

    DBCentri dbCentri = new DBCentri();
    dbCentri.preparaDb();

    _reqMock = new MockHttpServletRequest("GET",
        "/ricercheCentri.admin?action=elenco");
    _reqMock.setParameter(Constant.LETTERA, "c");
    ModelAndView mav = _controller.elenco(_reqMock, _resMock);
View Full Code Here

  }

  public void testPrepara() throws Exception {

    DBCentri dbCentri = new DBCentri();
    dbCentri.preparaDb();

    _reqMock = new MockHttpServletRequest("GET",
        "/ricercheCentri.admin?action=prepara");
    ModelAndView mav = _controller.prepara(_reqMock, _resMock);
    assertEquals("admin/ricercaAlfabeticaCentri", mav.getViewName());
View Full Code Here

 
  public void testElenco() throws Exception {

    DBCentri dbCentri = new DBCentri();
    dbCentri.preparaDb();
    DBPages dBPages = new DBPages();
    dBPages.preparaDb();

    _reqMock = new MockHttpServletRequest("GET",
        "/pages.admin?action=elenco");
View Full Code Here

  }

  public void testCentro() throws Exception {

    DBCentri dbCentri = new DBCentri();
    dbCentri.preparaDb();
    DBPages dBPages = new DBPages();
    dBPages.preparaDb();

    _reqMock = new MockHttpServletRequest("GET",
        "/pages.admin?action=centro");
View Full Code Here

  }

  public void testAdmin() throws Exception {

    DBCentri dbCentri = new DBCentri();
    dbCentri.preparaDb();
    DBPages dbPages = new DBPages();
    dbPages.preparaDb();

    _reqMock = new MockHttpServletRequest("GET",
        "/pages.admin?action=admin");
View Full Code Here

    dbGruppi = null;
  }

  public void testGetMailgruppi() {
    DBCentri dbC = new DBCentri();
    dbC.preparaDb();
    DBUtenti db = new DBUtenti();
    db.preparaDb();
   
    assertEquals(_service.getMailgruppi("1").size(), 5);
    assertEquals(_service.getMailgruppi("1,2").size(), 8);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.