Help with testing methods and classes in JUnit, using BlueJ
Hey all,
I need help with testing methods using JUnit. The editor we're using is BlueJ
This is my class:
Code:
package model;
import java.util.*;
public class Category
{
private String name;
private List<Appointment> appointments;
private List<ToDo> toDos;
public Category(String name)
{
this.name = name;
appointments = new ArrayList<Appointment>();
toDos = new ArrayList<ToDo>();
}
public String getName()
{
return this.name;
}
public void setName(String newName)
{
this.name = newName;
}
public void addAppointment(Appointment a)
{
appointments.add(a);
}
public void removeAppointment(Appointment a)
{
appointments.remove(a);
}
public void addToDo(ToDo t)
{
toDos.add(t);
}
public void removeToDo(ToDo t)
{
toDos.remove(t);
}
public List<Appointment> getAppointments()
{
return appointments;
}
public List<ToDo> getToDos()
{
return toDos;
}
}
I don't even really know where to begin :(