コード例 #1
0
        public void GetAvailableLanguagesTest()
        {
            TranslationDictionary myTransDict = new TranslationDictionary();

            myTransDict.Languages = new Language[] {
                new Language("german", new Word[] {}),
                new Language("chinese", new Word[] {})
            };

            string[] availablelangs = myTransDict.GetAvailableLanguages();
            Assert.AreEqual(Array.Find(availablelangs, n => n == "german"), "german");
            Assert.AreEqual(Array.Find(availablelangs, n => n == "chinese"), "chinese");
        }
コード例 #2
0
 /// <summary>
 /// returns the list of all available languages here.
 /// </summary>
 /// <returns></returns>
 public string[] GetLanguageList()
 {
     return(MyTranslationDictionary.GetAvailableLanguages());
 }