[Python-checkins] CVS: python/dist/src/Lib/test test_unicode.py,1.1,1.2

Guido van Rossum guido@cnri.reston.va.us
Mon, 13 Mar 2000 18:21:50 -0500 (EST)


Update of /projects/cvsroot/python/dist/src/Lib/test
In directory eric:/home/guido/hp/mal/py-patched/Lib/test

Modified Files:
	test_unicode.py 
Log Message:
Marc-Andre Lemburg: Add tests for mixed use of char in string.


Index: test_unicode.py
===================================================================
RCS file: /projects/cvsroot/python/dist/src/Lib/test/test_unicode.py,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** test_unicode.py	2000/03/10 23:23:20	1.1
--- test_unicode.py	2000/03/13 23:21:48	1.2
***************
*** 220,223 ****
--- 220,236 ----
  test('translate', u"abababc", u'iiix', {ord('a'):None, ord('b'):ord('i'), ord('c'):u'x'})
  
+ # Contains:
+ print 'Testing Unicode contains method...',
+ assert ('a' in 'abdb') == 1
+ assert ('a' in 'bdab') == 1
+ assert ('a' in 'bdaba') == 1
+ assert ('a' in 'bdba') == 1
+ assert ('a' in u'bdba') == 1
+ assert (u'a' in u'bdba') == 1
+ assert (u'a' in u'bdb') == 0
+ assert (u'a' in 'bdb') == 0
+ assert (u'a' in 'bdba') == 1
+ print 'done.'
+ 
  # Formatting:
  print 'Testing Unicode formatting strings...',