pub const ZH_CN: &str = "zh-CN";
pub const EN: &str = "en";

pub fn message(language: &str, zh: &'static str, en: &'static str) -> &'static str {
    if language == EN {
        en
    } else {
        zh
    }
}

#[cfg(test)]
mod tests {
    use super::*;
    #[test]
    fn selects_language() {
        assert_eq!(message(EN, "中", "en"), "en");
        assert_eq!(message(ZH_CN, "中", "en"), "中");
    }
}
