aboutsummaryrefslogtreecommitdiffstats
path: root/test_archivemail
Commit message (Collapse)AuthorAgeFilesLines
* test suite: bail out on python versions << 2.4Nikolaus Schulz2012-11-041-3/+3
| | | | | The test suite uses function that were introduced in Python 2.4 (e.g. set(), sorted()).
* Bump year in copyright notesNikolaus Schulz2011-07-091-1/+1
|
* test suite: adapt to new behaviour of parse_imap_url()Nikolaus Schulz2011-07-091-25/+15
| | | | This also removes some pretty bogus test URLs.
* test suite: add simple test for parsing IMAP urls specifying port numbersNikolaus Schulz2011-07-091-0/+13
|
* IMAP: add support for non-ascii mailbox namesNikolaus Schulz2011-07-051-0/+21
|
* test suite: let FixedGzipFile.seek() pass on what gzip.GzipFile.seek() returnedNikolaus Schulz2011-06-181-2/+4
| | | | | | | | | | | | | | | This fixes test suite failures with Python 2.7. Starting with Python 2.7, gzip.GzipFile is subclassing io.IOBase. The seek() method of io.IOBase differs from file.seek() and the old gzip.GzipFile.seek() in that it returns the new file position, not None. And in Python 2.7, gzip.GzipFile.tell() is inherited from io.IOBase.tell(), which is implemented using its seek() method. FixedGzipFile subclasses gzip.GzipFile and overrides seek(); therefore, this method need be adapted for this change in the interface. Closes: #3314293.
* IMAP: correctly handle IMAP `literal' and unquoted `astring' in LIST replyNikolaus Schulz2010-09-261-0/+20
| | | | | | | | | | | | The LIST reply handling in imap_find_mailboxes() was buggy in several ways. It expected a non-NIL hierarchy delimiter, and it assumed that the mailbox name in a LIST reply is always quoted; but it can be an astring, a quoted string, or a literal (see RFC 3501 for the definitions of these tokens). These variants should now all be interpreted correctly. In addition, quoted mailbox names are now handled more strictly to the letter of the RFC; this only affects mailbox names containing a " or a backslash, though.
* New option --archive-name, alias -a, to hard-code the archive filenameNikolaus Schulz2010-07-311-0/+28
|
* test suite: fix buggy test of --suffix and --prefix option parsingNikolaus Schulz2010-07-311-2/+2
|
* test suite: replace some plain assertions with TestCase.assertEqual()Nikolaus Schulz2010-07-311-4/+4
|
* Don't create hidden archives when archiving mailboxes with leading dots in ↵Nikolaus Schulz2010-07-311-0/+22
| | | | | | | | the name When archiving a mailbox with leading dots in the name and no archive name prefix specified, strip the dots off the archive name. This is targeting Maildir++ subfolders.
* Only use the default archive name suffix when the user specified no affixNikolaus Schulz2010-07-311-7/+32
| | | | Also add more archive name affix testing to the test suite.
* New option --archive-prefix, alias -pNikolaus Schulz2010-07-311-0/+34
| | | | | | | | | | | Technically, this works just like the --suffix option. This commit also updates the manpage accordingly. Currently, the prefix is not checked for slashes, so it could contain path components. (The same applies for the suffix, btw). Since the expanded string is prepended to the archive base name, this can be used to dynamically configure the archive directory, depending on the archive cutoff date. I'm not sure if this can be considered a reasonable feature, though.
* Detect and never archive IMAP server pseudo mbox messagesNikolaus Schulz2010-07-301-0/+22
| | | | | | | IMAP servers (Dovecot and UW-IMAP at least) may store mailbox meta data for mboxes in a pseudo message. Such messages are now detected and never archived. This commit includes a test case in the test suite.
* test suite: test unlocking an mbox after dotlocking failed with EACCESNikolaus Schulz2010-07-301-0/+1
|
* Rename archivemail.py to archivemailNikolaus Schulz2010-07-291-7/+7
| | | | | | | | | On Unix, most scripts don't come with a file extension, it's not needed, and we distribute the script as "archivemail" anyway. And most importantly, I like it better without the extension. :) With a little trick we can still load the script as a module from the test suite.
* Drop .py extension from the unittest scriptNikolaus Schulz2010-07-291-0/+1593