/// <exception cref="System.Exception"/> private void CheckTranslation(string from, string to) { System.Console.Out.WriteLine("Translate " + from); KerberosName nm = new KerberosName(from); string simple = nm.GetShortName(); System.Console.Out.WriteLine("to " + simple); Assert.Equal("short name incorrect", to, simple); }
// PASS private void CheckBadTranslation(string from) { System.Console.Out.WriteLine("Checking bad translation for " + from); KerberosName nm = new KerberosName(from); try { nm.GetShortName(); NUnit.Framework.Assert.Fail("didn't get exception for " + from); } catch (IOException) { } }