mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-10-13 15:57:12 +00:00
Added test for character escape
This commit is contained in:
1 parent
a0b15d0c8c
commit
9ed3812795
2 files changed
+14
-1
No files matched your search
@@ -0,0 +1,6 @@
|
||||
{\rtf1\adeflang1025\ansi\ansicpg1252\uc1\adeff31507\deff0\stshfdbch31506\stshfloch31506\stshfhich31506\stshfbi31507\deflang3082\deflangfe3082\themelang3082\themelangfe0\themelangcs0{\fonttbl{\f0\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f0\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f37\fbidi \fswiss\fcharset0\fprq2{\*\panose 020f0502020204030204}Calibri;}{\f31500\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f31501\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f31502\fbidi \froman\fcharset0\fprq2{\*\panose 02040503050406030204}Cambria;}{\f31503\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f31504\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f31505\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f31506\fbidi \fswiss\fcharset0\fprq2{\*\panose 020f0502020204030204}Calibri;}{\f31507\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f180\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f181\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f183\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f184\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f185\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f186\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f187\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f188\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f180\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f181\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f183\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f184\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f185\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f186\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f187\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f188\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f550\fbidi \fswiss\fcharset238\fprq2 Calibri CE;}{\f551\fbidi \fswiss\fcharset204\fprq2 Calibri Cyr;}{\f553\fbidi \fswiss\fcharset161\fprq2 Calibri Greek;}{\f554\fbidi \fswiss\fcharset162\fprq2 Calibri Tur;}{\f557\fbidi \fswiss\fcharset186\fprq2 Calibri Baltic;}{\f558\fbidi \fswiss\fcharset163\fprq2 Calibri (Vietnamese);}{\f31508\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f31509\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f31511\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f31512\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f31513\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f31514\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f31515\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f31516\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f31518\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f31519\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f31521\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f31522\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f31523\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f31524\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f31525\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f31526\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f31528\fbidi \froman\fcharset238\fprq2 Cambria CE;}{\f31529\fbidi \froman\fcharset204\fprq2 Cambria Cyr;}{\f31531\fbidi \froman\fcharset161\fprq2 Cambria Greek;}{\f31532\fbidi \froman\fcharset162\fprq2 Cambria Tur;}{\f31535\fbidi \froman\fcharset186\fprq2 Cambria Baltic;}{\f31536\fbidi \froman\fcharset163\fprq2 Cambria (Vietnamese);}{\f31538\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f31539\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f31541\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f31542\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f31543\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f31544\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f31545\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f31546\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f31548\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f31549\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f31551\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f31552\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f31553\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f31554\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\f31555\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f31556\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f31558\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f31559\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\f31561\fbidi \fromLine truncated
|
||||
{\rtlch\fcs1 \af31507 \ltrch\fcs0 \cf0\insrsid12347655 x\341x\351x\372x\355x\363x\361x}
|
||||
{\rtlch\fcs1 \af31507 \ltrch\fcs0 \cf0\insrsid12347655 S\~S\-S\_S\\S}
|
||||
{\rtlch\fcs1 \af31507 \ltrch\fcs0 \cf0\insrsid12347655 U\u-2U\u345U}
|
||||
|
||||
{\rtlch\fcs1 \af31507 \ltrch\fcs0 \cf0\insrsid12347655\charrsid12347655 \r\n\par }}}
|
||||
@@ -285,8 +285,15 @@
|
||||
NSString *file =@"mini_russian.rtf";
|
||||
NSString *expected=@"<html><meta charset='utf-8'><body><font face=\"Calibri\"><font face=\"Calibri Cyr\"><font color=\"#000000\">XXзык польски, польщизнаXX</font></font></font></body></html>";
|
||||
[self checkHTMLConversionOfRTFFile: file
|
||||
againstExpectedHTML: expected];
|
||||
againstExpectedHTML: expected];
|
||||
}
|
||||
|
||||
- (void) test_escapes
|
||||
{
|
||||
NSString *file =@"escapes.rtf";
|
||||
NSString *expected=@"<html><meta charset='utf-8'><body><font face=\"Calibri\"><font color=\"#000000\">x341x351x372x355x363x361x</font><font color=\"#000000\">S SS-S\\S</font><font color=\"#000000\">U老UřU</font><font color=\"#000000\"><br></font></font></body></html>";
|
||||
[self checkHTMLConversionOfRTFFile: file
|
||||
againstExpectedHTML: expected];
|
||||
}
|
||||
|
||||
@end
|
||||
Reference in new issue
Block a user