Exemplo n.º 1
0
        public void ShouldParseParameterizedTypes()
        {
            Hl7TypeName name = new Hl7TypeParser().Parse("SET<ST>");

            NUnit.Framework.Assert.AreEqual("SET<ST>", ((String)name.ToString()), "name");
            NUnit.Framework.Assert.AreEqual("SET", name.UnparameterizedName, "base");
        }
Exemplo n.º 2
0
        public void ShouldStripWhitespace()
        {
            Hl7TypeName name = new Hl7TypeParser().Parse("SET<RTO<PQ, PQ>>");

            NUnit.Framework.Assert.AreEqual("SET<RTO<PQ,PQ>>", ((String)name.ToString()), "name");
            NUnit.Framework.Assert.AreEqual("SET", name.UnparameterizedName, "base");
            NUnit.Framework.Assert.AreEqual(1, name.Parameters.Count, "parameter count");

            Hl7TypeName parameter = name.Parameters[0];

            NUnit.Framework.Assert.AreEqual("RTO", parameter.UnparameterizedName, "parameter name");
            NUnit.Framework.Assert.AreEqual(2, parameter.Parameters.Count, "parameters of parameter count");
        }
Exemplo n.º 3
0
        public void ShouldParseSimpleCase()
        {
            Hl7TypeName name = new Hl7TypeParser().Parse("ST");

            NUnit.Framework.Assert.AreEqual("ST", ((String)name.ToString()), "name");
        }