def create_checkin_and_association(barista, company, checkedin): checkin = checkIn() checkin.barista = User.objects.get(username=barista.username) checkin.location = companyLocation.objects.get(companyID=company) checkin.inTime = timezone.now() checkin.outTime = timezone.now() checkin.checkedin = checkedin checkin.save()
def test_get_fav_bar_checked_in_returns_checkIn_obj(self): self.assertEquals(type(self.userdetails.get_favBarCheckIn()), type(checkIn()))
def test_get_checkins_query_has_checkIn_object(self): checkinsquery = self.company_location.get_checkins() for checkin in checkinsquery: self.assertEquals(type(checkIn()), type(checkin))