'Creating an approved revision updates document.html'

def test_approved_revision_updates_html(self):

    rev = revision(is_approved=True, save=True, content='Replace    document    html')
    assert ('Replace    document    html' in rev.document.html), ('"Replace    document    html"    not    in    %s' % rev.document.html)
    r = revision(document=rev.document, content='Replace    html    again', is_approved=True)
    r.save()
    assert ('Replace    html    again' in rev.document.html), ('"Replace    html    again"    not    in    %s' % rev.document.html)
