[Modeling-cvs] ProjectModeling/Modeling/tests test_EditingContext_Global.py,1.32,1.33
Status: Abandoned
Brought to you by:
sbigaret
From: <sbi...@us...> - 2003-07-24 12:07:31
|
Update of /cvsroot/modeling/ProjectModeling/Modeling/tests In directory sc8-pr-cvs1:/tmp/cvs-serv29656/tests Modified Files: test_EditingContext_Global.py Log Message: Fixed bug #776592: was impossible to add raw '*' and '?' characters in a LIKE statement Index: test_EditingContext_Global.py =================================================================== RCS file: /cvsroot/modeling/ProjectModeling/Modeling/tests/test_EditingContext_Global.py,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** test_EditingContext_Global.py 24 Jul 2003 11:30:52 -0000 1.32 --- test_EditingContext_Global.py 24 Jul 2003 12:07:25 -0000 1.33 *************** *** 1077,1080 **** --- 1077,1103 ---- ## check: modify / delete / saveChanges / insert + def test_23_fetch_star_and_interrogation_mark_chars(self): + "[EditingContext] fetch real '?' and '*'" + ec=EditingContext() + b1=Book(); b1.setTitle('abc?d') + b2=Book(); b2.setTitle('abcXd') + b3=Book(); b3.setTitle('abc*d') + ec.insert(b1); ec.insert(b2); ec.insert(b3) + ec.saveChanges() + + res=ec.fetch('Book', 'title like "abc?d"') + self.failIf(len(res)!=3) + + res=ec.fetch('Book', 'title like "abc*d"') + self.failIf(len(res)!=3) + + res=ec.fetch('Book', 'title like "abc\?d"') + self.failIf(len(res)!=1) + self.failIf(res[0].getTitle()!='abc?d') + + res=ec.fetch('Book', 'title like "abc\*d"') + self.failIf(len(res)!=1) + self.failIf(res[0].getTitle()!='abc*d') + def test_999_customSQLQuery(self): "[EditingContext] custom SQL Query" |