def test_inline_styling(self): html = ''' <h3>Hi John</h3> <p>This is a test email</p> ''' transformed_html = ''' <h3>Hi John</h3> <p style="margin:1em 0 !important">This is a test email</p> ''' self.assertTrue(transformed_html in inline_style_in_html(html))