public void ParseTest()
        {
            compositeMessage ack = new compositeMessage(null, "ACK");
            EVN evn = new EVN(ack, "EVN");

            evn.Parse("EVN|A01|199806051529");
            Assert.AreEqual("EVN|A01|199806051529", evn.Value);
        }
        public void compositeFieldTest()
        {
            compositeMessage ack = new compositeMessage(null, "ACK");
            EVN evn = new EVN(ack, "EVN");

            evn.Value = "EVN|A01|199806051529";
            Assert.AreEqual("199806051529", evn.Value);
        }
Beispiel #3
0
        public void MSHTest()
        {
            compositeMessage message = new compositeMessage(null, "ACK");
            MSH msh = new MSH(message, "MSH");

            msh.Value = "MSH|^~\\&|HIS|00001|LIS|1234|2004112754000||ACK^A01^ACK_A01|0200002|P|2.4\rMSA|AE|0200001|type error|||102\r";
            Assert.AreEqual("2004112754000", msh.DateTimeOfMessage.Time.Value);
        }
Beispiel #4
0
        public void ToStringTest()
        {
            compositeMessage message = new compositeMessage(null, "ACK");
            MSH msh = new MSH(message, "MSH");

            msh.FieldSeparator.Value = "|";
            msh.ReceivingApplication.NamespaceID.Value = "LIS";
            Assert.AreEqual("MSH||||LIS", msh.ToString());
        }
Beispiel #5
0
        public void ParseTest()
        {
            compositeMessage message = new compositeMessage(null, "ACK");
            MSH msh = new MSH(message, "MSH");

            msh.Parse("MSH|^~\\&|HIS|00001|LIS|1234|2004112754000||" +
                      "ACK^A01^ACK_A01|0200002|P|2.4\rMSA|AE|" +
                      "0200001|type error|||102");

            /*
             * Assert.AreEqual("|", msh.FieldSeparator.Value);
             * Assert.AreEqual("LIS", msh.ReceivingApplication.NamespaceID.Value);
             * Assert.AreEqual("HIS", msh.SendingApplication.NamespaceID.Value);
             * Assert.AreEqual(null, msh.Security.Value);
             * Assert.AreEqual("ACK", msh.MessageType.MessageType.Value);
             * Assert.AreEqual("A01", msh.MessageType.TriggerEvent.Value);
             * Assert.AreEqual("P", msh.ProcessingID.ProcessingID.Value);
             * Assert.AreEqual("0200001", msh.ContinuationPointer.Value);
             */
            // Assert.AreEqual("102", msh.CharacterSet.Value);
            Assert.AreEqual("MSH|^~\\&|HIS|00001|LIS|1234|2004112754000||" +
                            "ACK^A01^ACK_A01|0200002|P|2.4\rMSA|AE|" +
                            "0200001|type error|||102", msh.Value);
        }