'POSTing non-ascii to kumascript should encode to utf8'

@override_config(KUMASCRIPT_TIMEOUT=1.0, KUMASCRIPT_MAX_AGE=600)
@requests_mock.mock()
def test_preview_nonascii(self, mock_requests):

    content = u'Fran\xe7ais'
    mock_requests.post(requests_mock.ANY, content=content.encode('utf8'))
    self.client.login(username='admin', password='testpass')
    self.client.post(reverse('wiki.preview'), {'content': content})
    try:
        mock_requests.request_history[0].body.decode('utf8')
    except UnicodeDecodeError:
        self.fail("Data    wasn't    posted    as    utf8")
