def do_login(self, user, password):
    data = {'email': user.email, 'first_name': user.first_name, 'last_name': user.last_name, 'password': password}
    response = self.client.post(reverse('accounts:signin'), data, format='json')
    token = response.data['access']
    self.client.credentials(HTTP_AUTHORIZATION=f'Bearer {token}')
def do_login(self, user, password):
    data = {'email': user.email, 'first_name': user.first_name, 'last_name': user.last_name, 'password': password}
    response = self.client.post(reverse('accounts:signin'), data, format='json')
    token = response.data['access']
    self.client.credentials(HTTP_AUTHORIZATION=f'Bearer {token}')