Added get_languages(), detect_language() functions and test cases for them