@Test public void testFindTagsByTask() throws Exception { Map<String, Integer> tags = taskService.findTagsByTask(taskService.getTaskByID(1).get()); for (Map.Entry<String, Integer> entry : tags.entrySet()) { assertNotEquals("", entry.getKey()); } }
@Test public void testGetTaskByID() throws Exception { Optional<Task> optTask = taskService.getTaskByID(1); assertTrue(optTask.isPresent()); Task task = optTask.get(); assertNotNull(task); assertEquals(1, task.getId()); assertNotNull(task.getName()); assertNotNull(task.getDescription()); assertNotNull(task.getTestSteps()); assertNotNull(task.getCreator()); assertNotNull(task.getAssignee()); assertNotNull(task.getStatus()); assertNotNull(task.getPriority()); assertNotNull(task.getType()); }