public virtual void testCreateAttribute() { XMLDoc d = new XMLDoc("TEST", null); XmlAttribute a = d.createAttribute("dom1"); Assert.IsNotNull(a, "a"); bool bcatch = false; try { d.createAttribute("xmlns:foo"); } catch (Exception) { bcatch = true; } Assert.IsTrue(!bcatch, "catch b"); bcatch = false; try { d.createAttribute("foo:dom1"); } catch (Exception) { bcatch = true; } Assert.IsTrue(!bcatch, "catch c"); }