diff --git a/src/smtp/common.rs b/src/smtp/common.rs index 3cc1b01..2582388 100644 --- a/src/smtp/common.rs +++ b/src/smtp/common.rs @@ -52,15 +52,15 @@ pub fn get_first_word(string: StrBuf) -> StrBuf { mod test { #[test] fn test_quote_email_address() { - assert_eq!(super::quote_email_address(StrBuf::from_str("plop")), StrBuf::from_str("")); - assert_eq!(super::quote_email_address(StrBuf::from_str("")), StrBuf::from_str("")); + assert_eq!(super::quote_email_address(StrBuf::from_str("address")), StrBuf::from_str("
")); + assert_eq!(super::quote_email_address(StrBuf::from_str("
")), StrBuf::from_str("
")); } #[test] fn test_unquote_email_address() { - assert_eq!(super::unquote_email_address(StrBuf::from_str("")), StrBuf::from_str("plop")); - assert_eq!(super::unquote_email_address(StrBuf::from_str("plop")), StrBuf::from_str("plop")); - assert_eq!(super::unquote_email_address(StrBuf::from_str("")), StrBuf::from_str("address")); + assert_eq!(super::unquote_email_address(StrBuf::from_str("address")), StrBuf::from_str("address")); + assert_eq!(super::unquote_email_address(StrBuf::from_str(" = +//! let mut email_client: SmtpClient = //! SmtpClient::new(StrBuf::from_str("localhost"), None, None); //! email_client.send_mail( //! StrBuf::from_str("user@example.com"), @@ -43,19 +43,24 @@ //! ``` #![crate_id = "smtp#0.1-pre"] +#![crate_type = "rlib"] +#![crate_type = "dylib"] #![desc = "Rust SMTP client"] #![comment = "Simple SMTP client"] #![license = "MIT/ASL2"] -#![crate_type = "lib"] - #![feature(macro_rules)] +#![feature(phase)] #![deny(non_camel_case_types)] #![deny(missing_doc)] +#![deny(unnecessary_qualification)] +#![deny(non_uppercase_statics)] +#![deny(unnecessary_typecast)] +#![deny(unused_result)] +#![deny(deprecated_owned_vector)] -#![feature(phase)] -#[phase(syntax, link)] extern crate log; +#[feature(phase)] #[phase(syntax, link)] extern crate log; pub mod commands; pub mod common;