@Test public void find_findsTaskInDatabase_true() { Task myTask = new Task("Mow the lawn", 1); myTask.save(); Task savedTask = Task.find(myTask.getId()); assertTrue(myTask.equals(savedTask)); }
@Test public void testGetTask() { Task testTask = new Task(1, "Task2", Priority.HIGH); assertTrue(testTask.equals(userstory.getTaskById(1))); }
@Test public void equals_returnsTrueIfDescriptionsAretheSame() { Task firstTask = new Task("Mow the lawn", 1); Task secondTask = new Task("Mow the lawn", 1); assertTrue(firstTask.equals(secondTask)); }