[Python-checkins] python/dist/src/Lib/bsddb/test test_join.py,1.5,1.6

bwarsaw@users.sourceforge.net bwarsaw@users.sourceforge.net
Mon, 21 Jul 2003 11:43:35 -0700


Update of /cvsroot/python/python/dist/src/Lib/bsddb/test
In directory sc8-pr-cvs1:/tmp/cvs-serv10365

Modified Files:
	test_join.py 
Log Message:
test01_join(): Fix a test failure when run with "python -O".  The
setting of sCursor happened in an assert.


Index: test_join.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/bsddb/test/test_join.py,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** test_join.py	9 Jul 2003 05:33:14 -0000	1.5
--- test_join.py	21 Jul 2003 18:43:33 -0000	1.6
***************
*** 86,90 ****
              # lets look up all of the red Products
              sCursor = secDB.cursor()
!             assert sCursor.set('red')
  
              # FIXME: jCursor doesn't properly hold a reference to its
--- 86,93 ----
              # lets look up all of the red Products
              sCursor = secDB.cursor()
!             # Don't do the .set() in an assert, or you can get a bogus failure
!             # when running python -O
!             tmp = sCursor.set('red')
!             assert tmp
  
              # FIXME: jCursor doesn't properly hold a reference to its