added some testcases for MimeMessage parsing + some simple refactorings (deleted unused code, ...)