Examples of Tarefa


Examples of org.universa.tcc.gemda.entidade.Tarefa

    facade.excluir(tarefa);
  }

  @Test
  public void testExcluirTarefa() throws Exception {
    Tarefa tarefa = new Tarefa(null, "Teste", criarUsuario(), criarStory(), Passo.TO_DO);
    facade.inserir(tarefa);
    assertNotNull(tarefa.getId());
    facade.excluir(tarefa);
    Tarefa tarefaExcluida = facade.recuperar(Tarefa.class, tarefa.getId());
    assertNull(tarefaExcluida);
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    Tarefa tarefaExcluida = facade.recuperar(Tarefa.class, tarefa.getId());
    assertNull(tarefaExcluida);
  }
 
  public void testRecuperarTarefaInvalido() throws Exception {
    Tarefa terafa = new Tarefa(null, "Teste", criarUsuario(), criarStory(), Passo.DONE);
    facade.inserir(terafa);
    assertNotNull(terafa.getId());
    Tarefa tarefaRecuperada = facade.recuperar(Tarefa.class, null);
    assertNotNull(tarefaRecuperada);
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    assertNotNull(tarefaRecuperada);
  }
 
  @Test
  public void testRecuperarTarefa() throws Exception {
    Tarefa terafa = new Tarefa(null, "Teste", criarUsuario(), criarStory(), Passo.DONE);
    facade.inserir(terafa);
    assertNotNull(terafa.getId());
    Tarefa tarefaRecuperada = facade.recuperar(Tarefa.class, terafa.getId());
    assertNotNull(tarefaRecuperada);
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    assertFalse(tarefas.isEmpty());
  }
 
  @Test
  public void testPesquisarTarefa() throws Exception {
    Tarefa tarefa = new Tarefa();
    tarefa.setPasso(Passo.TO_DO);
    Collection<Tarefa> tarefas = facade.pesquisar(tarefa);
    assertFalse(tarefas.isEmpty());
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    assertFalse(count == 0);
  }
 
  @Test
  public void testCountTarefa() throws Exception {
    long count = facade.count(new Tarefa(null, null, null, null, Passo.DONE));
    assertFalse(count == 0);
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    assertNotNull(usuario.getId());
    return usuario;
  }
 
  protected Tarefa criarTarefa() throws Exception {
    Tarefa tarefa = new Tarefa(null, "Criar classe de Usu�rio.", criarUsuario(), criarStory(), Passo.TO_DO);
    tarefaDAO.inserir(tarefa);
    assertNotNull(tarefa.getId());
    return tarefa;
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    assertNotNull(projeto.getId());
    return projeto;
  }
 
  protected Tarefa criarTarefa() throws Exception {
    Tarefa tarefa = new Tarefa(null, "Criar a camada de fachada.", criarUsuario(), criarStory(), Passo.TO_DO);
    tarefaService.inserir(tarefa);
    assertNotNull(tarefa.getId());
    return tarefa;
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

public class TarefaServiceTest extends ServiceTestCase {
 
  public void testInserirTarefaInvalido() throws Exception {
    try {
      Tarefa tarefa = new Tarefa();
      tarefaService.inserir(tarefa);
      assertNotNull(tarefa.getId());
    } catch (ValidationException e) {
      throwValidations(e);
    }
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    }
  }
 
  @Test
  public void testInserirTarefa() throws Exception {
    Tarefa tarefa = new Tarefa(null, "Implementar as classes de dom�nio do GeMDA!", criarUsuario(), criarStory(), Passo.TO_DO);
    tarefaService.inserir(tarefa);
    assertNotNull(tarefa.getId());
  }
View Full Code Here

Examples of org.universa.tcc.gemda.entidade.Tarefa

    assertNotNull(tarefa.getId());
  }
 
  public void testAlterarTarefaInvalido() throws Exception {
    try {
      Tarefa tarefa = new Tarefa(null, "Teste", criarUsuario(), criarStory(), Passo.TO_DO);
      tarefaService.inserir(tarefa);
      assertNotNull(tarefa.getId());
      tarefa.setUsuario(new Usuario());
      tarefa.setStory(new Story());
      tarefa.setDescricao("");
      tarefa.setPasso(null);
      tarefaService.alterar(tarefa);
      Tarefa tarefaAlterada = tarefaService.recuperar(tarefa.getId());
      assertEquals(Passo.DOING, tarefaAlterada.getPasso());
    } catch (ValidationException e) {
      throwValidations(e);
    }
  }
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.