@@ -275,7 +275,8 @@ def login(self, user, password):
275275
276276 (typ, [data]) = <instance>.list(user, password)
277277 """
278- if not 'AUTH-LOGIN' in self .capabilities :
278+ if not 'AUTH=LOGIN' in self .capabilities \
279+ and not 'AUTH-LOGIN' in self .capabilities :
279280 raise self .error ("server doesn't allow LOGIN authorisation" )
280281 typ , dat = self ._simple_command ('LOGIN' , user , password )
281282 if typ != 'OK' :
@@ -391,6 +392,8 @@ def status(self, mailbox, names):
391392 (typ, [data]) = <instance>.status(mailbox, names)
392393 """
393394 name = 'STATUS'
395+ if self .PROTOCOL_VERSION == 'IMAP4' :
396+ raise self .error ('%s unimplemented in IMAP4 (obtain IMAP4rev1 server, or re-code)' % name )
394397 typ , dat = self ._simple_command (name , mailbox , names )
395398 return self ._untagged_response (typ , name )
396399
@@ -783,7 +786,7 @@ def run(cmd, args):
783786 return dat
784787
785788 Debug = 4
786- M = IMAP4 ("newcnri" )
789+ M = IMAP4 ()
787790 print 'PROTOCOL_VERSION = %s' % M .PROTOCOL_VERSION
788791
789792 for cmd ,args in test_seq1 :
0 commit comments