示例#1
0
 def test6(self):        
     anm = AlphaNumMatcher()
     
     for char in ";@#$abcd1234efgh5678":
         anm.feed(char)
         
     self.assertEqual(anm.getvalue(), "abcd1234efgh5678")
示例#2
0
 def test4(self):        
     anm = AlphaNumMatcher()
     
     for char in "1234":
         anm.feed(char)
     
     self.assertEqual(anm.getvalue(), "1234")
示例#3
0
 def test7(self):        
     anm = AlphaNumMatcher()
     
     for char in " ;!@#$%^&*()\/?[]{}+=-~`'\"|.,":
         s = anm.feed(char)
         self.failIf(s)
     
     for char in "abcd1234":
         s = anm.feed(char)
         self.failUnless(s)
     
     for char in " ;!@#$%^&*()\/?[]{}+=-~`'\"|.,":
         s = anm.feed(char)
         self.failIf(s)
示例#4
0
 def test3(self):        
     anm = AlphaNumMatcher()
     
     for char in " ;!@#$%^&*()\/?[]{}+=-~`'\"|.,":
         s = anm.feed(char)
         self.failIf(s)
示例#5
0
 def test2(self):        
     anm = AlphaNumMatcher()
     
     for char in "1234":
         s = anm.feed(char)
         self.failUnless(s)
示例#6
0
 def test1(self):        
     anm = AlphaNumMatcher()
     
     for char in "abcd":
         s = anm.feed(char)
         self.failUnless(s)