use of net.johnpwood.android.standuptimer.model.Team in project standup-timer by jwood.
the class TeamDAOTest method test_can_update_an_existing_team.
@MediumTest
public void test_can_update_an_existing_team() {
Team team1 = dao.save(new Team("Test Team 1"));
dao.save(new Team(team1.getId(), "Test Team 2"));
Team team = dao.findById(team1.getId());
assertEquals("Test Team 2", team.getName());
}
use of net.johnpwood.android.standuptimer.model.Team in project standup-timer by jwood.
the class TeamDAOTest method test_create_a_team_with_an_apostrophy_in_the_name.
@MediumTest
public void test_create_a_team_with_an_apostrophy_in_the_name() {
Team team = new Team("John's Team");
team = dao.save(team);
assertNotNull(team.getId());
assertEquals("John's Team", team.getName());
}
use of net.johnpwood.android.standuptimer.model.Team in project standup-timer by jwood.
the class MeetingTest method test_delete_all_by_team.
@MediumTest
public void test_delete_all_by_team() {
Team team = new Team("Test Team");
new Meeting(team, new GregorianCalendar(2010, 1, 5, 10, 15, 0).getTime(), 5, 240, 300, 30, 120).save(mContext);
new Meeting(team, new GregorianCalendar(2010, 1, 4, 10, 15, 0).getTime(), 5, 240, 300, 30, 120).save(mContext);
;
assertFalse(Meeting.findAllByTeam(team, mContext).isEmpty());
Meeting.deleteAllByTeam(team, mContext);
assertTrue(Meeting.findAllByTeam(team, mContext).isEmpty());
}
use of net.johnpwood.android.standuptimer.model.Team in project standup-timer by jwood.
the class MeetingTest method test_save_a_meeting.
@MediumTest
public void test_save_a_meeting() {
Meeting meeting = new Meeting(new Team("Test Team"), new GregorianCalendar(2010, 1, 5, 10, 15, 0).getTime(), 5, 240, 300, 30, 120);
meeting = meeting.save(mContext);
assertNotNull(meeting.getId());
}
use of net.johnpwood.android.standuptimer.model.Team in project standup-timer by jwood.
the class TeamList method deleteTeam.
private void deleteTeam(String teamName) {
Team team = Team.findByName(teamName, this);
team.delete(this);
}
Aggregations