def test_get_or_create_got_user(self): user, created = User.get_or_create(email='bon@äcdc.com') self.assertFalse(created) self.assertEqual(user.email, 'bon@äcdc.com')
def test_get_or_create_doesnotexist(self): user, created = User.get_or_create(email='bon@äcdc.com') self.assertTrue(created) self.assertEqual(user.email, 'bon@äcdc.com')