def test_getAlternateMIMETypesMixed(self): """ Test that there are no alternate MIME types returned by L{xquotient.exmess.MessageBodyFragment.getAlternateMIMETypes} for L{mixed} """ self.setUpMailStuff() m = self.createMIMEReceiver().feedStringNow(self.mixed).message messageBody = MessageBodyFragment(m, 'text/plain') self.assertEqual(list(messageBody.getAlternateMIMETypes()), [])
def test_getAlternateMIMETypesMixed(self): """ Test that there are no alternate MIME types returned by L{xquotient.exmess.MessageBodyFragment.getAlternateMIMETypes} for L{mixed} """ self.setUpMailStuff() m = self.createMIMEReceiver().feedStringNow( self.mixed).message messageBody = MessageBodyFragment(m, 'text/plain') self.assertEqual( list(messageBody.getAlternateMIMETypes()), [])
def test_alternateMIMETypesAltMixed(self): """ Test that C{text/html} is the only alternate MIME type returned by L{xquotient.exmess.MessageBodyFragment.getAlternateMIMETypes} for L{altInsideMixed} """ self.setUpMailStuff() m = self.createMIMEReceiver().feedStringNow( self.altInsideMixed).message messageBody = MessageBodyFragment(m, 'text/plain') self.assertEqual(list(messageBody.getAlternateMIMETypes()), ['text/html'])
def test_alternateMIMETypesAltMixed(self): """ Test that C{text/html} is the only alternate MIME type returned by L{xquotient.exmess.MessageBodyFragment.getAlternateMIMETypes} for L{altInsideMixed} """ self.setUpMailStuff() m = self.createMIMEReceiver().feedStringNow( self.altInsideMixed).message messageBody = MessageBodyFragment(m, 'text/plain') self.assertEqual( list(messageBody.getAlternateMIMETypes()), ['text/html'])