Guest User

Untitled

a guest
Jul 23rd, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. @mock.patch('django_testing.models.SampleManager.get_last')
  2. @mock.patch('django_testing.models.SampleManager.get_first')
  3. def test_result_of_one_query_in_args_of_another(self, get_first, get_last):
  4. result = models.Sample.objects.get_first_and_last()
  5. self.assertEqual((get_first.return_value, get_last.return_value), result)
Add Comment
Please, Sign In to add comment