Make sure to set the right content type when creating test messages (application/sieve is not declared/added to the mailcap so oracle javamail allow an undocumented behaviour, while geronimo is more strict and remove the unknown content type).