def test_filter_unicode(self): # issue22 # This test passes with Python >= 2.6 either way. obj = TestModel() obj.xstring = 'foo' obj.save() query = db.GqlQuery((u'SELECT * FROM RegressionTestModel' u' WHERE xstring = :foo'), foo=u'foo') self.assertEqual(query.count(), 1)
def test_filter_unicode(self): # issue22 # This test passes with Python >= 2.6 either way. obj = TestModel() obj.xstring = 'foo' obj.save() query = db.GqlQuery((u'SELECT * FROM RegressionTestModel' u' WHERE xstring = :foo'), foo=u'foo') self.assertEqual(query.count(), 1)
def setUp(self): TestModel.objects.all().delete() for i in range(10): obj = TestModel() obj.xstring = 'foo%d' % i obj.save()
def setUp(self): TestModel.objects.all().delete() for i in range(10): obj = TestModel() obj.xstring = 'foo%d' % i obj.save()
def test_dbwrite(self): # Note: This test mainly makes sense with PostgreSQL backend. obj = RegressionTestModel() obj.xstring = CallableString(u"möhrenbrei") obj.save()