public void TestGetFormat()
 {
     var info = new NodaCultureInfo("en-US");
     var nodaFormatInfo = info.GetFormat(typeof(NodaFormatInfo));
     Assert.NotNull(nodaFormatInfo, "GetFormat supoprts NodaFormatInfo");
     var numberFormatInfo = info.GetFormat(typeof(NumberFormatInfo));
     Assert.NotNull(numberFormatInfo, "NodaCultureInfo passes GetFormat() to underlying CultureInfo");
 }
 public void TestNodaFormatInfo_set()
 {
     var info = new NodaCultureInfo("en-US");
     var original = info.NodaFormatInfo;
     Assert.NotNull(original);
     var newFormat = new NodaFormatInfo(Thread.CurrentThread.CurrentCulture);
     Assert.AreNotSame(original, newFormat);
     info.NodaFormatInfo = newFormat;
     Assert.AreSame(newFormat, info.NodaFormatInfo);
 }
 public void TestGetInstance_NodaCultureInfo()
 {
     NodaFormatInfo.ClearCache();
     using (CultureSaver.SetCultures(enUs, FailingCultureInfo.Instance))
     {
         var info = new NodaCultureInfo("en-GB");
         var actual = NodaFormatInfo.GetInstance(info);
         Assert.AreSame(info.Name, actual.Name);
     }
 }
 public void TestToString()
 {
     const string name = "en-US";
     var info = new NodaCultureInfo(name);
     const string toString = "NodaCultureInfo: " + name;
     Assert.AreEqual(toString, info.ToString());
 }
 public void TestParent()
 {
     var info = new NodaCultureInfo("en-US");
     var actual = info.Parent;
     Assert.NotNull(actual);
     Assert.AreEqual("en", actual.Name);
 }