Example #1
0
 def test_setting_and_saving_attributes(self):
     m = MyUser(username='user2', email='[email protected]', password='dummy',
                tags='tag1 tag2')
     m.save()
     del m
     m = MyUser.objects.get(username='user2')
     self.assertEquals(m.tags, 'tag1 tag2')
Example #2
0
 def test_saving(self):
     m = MyUser(username='user2', email='[email protected]', password='dummy',
                tags='tag1 tag2')
     m.save()
     self.assertEquals(MyUser.objects.filter(username='user2').count(), 1)
Example #3
0
 def test_passing_parameters(self):
     m = MyUser()
     m.tags = 'tag1 tag2'
     self.assertEquals(m.tags, 'tag1 tag2')