I thought I had a working solution using the \n
character, but after performing a quick test I couldn’t make it work.
What did work was using the <br />
tag like this.
Key: <html>This<br />is<br />a<br />test
Spanish translation: <html>Esta<br />es<br />una<br />prueba
>>> term = '<html>This<br />is<br />a<br />test'
>>> print system.util.translate(term, 'es')
<html>Esta<br />es<br />una<br />prueba
Maybe this might work for you.