mirror of
https://github.com/chatmail/core.git
synced 2026-04-26 01:46:34 +03:00
add test apostrophed-encoding with cp1252 charset (aka ANSI aka Windows-1252)
This commit is contained in:
@@ -1568,6 +1568,15 @@ mod tests {
|
||||
assert_eq!(filename, Some("программирование.HTM".to_string()))
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_get_attachment_filename_apostrophed_cp1252() {
|
||||
let mail = load_mail_with_attachment(include_bytes!(
|
||||
"../test-data/message/attach_filename_apostrophed_cp1252.eml"
|
||||
));
|
||||
let filename = get_attachment_filename(&mail.subparts[1]).unwrap();
|
||||
assert_eq!(filename, Some("Auftragsbestätigung.pdf".to_string()))
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_get_attachment_filename_combined() {
|
||||
// test that if `filename` and `filename*0` are given, the filename is not doubled
|
||||
|
||||
Reference in New Issue
Block a user