public void FromDelimitedString_WithIncorrectSegmentId_ThrowsArgumentException() { Assert.Throws <ArgumentException>(() => { ISegment hl7Segment = new Gp1Segment(); hl7Segment.FromDelimitedString("GPA|^~&|3|4|5|6"); }); }
public void FromDelimitedString_WithAllProperties_ReturnsCorrectlyInitializedFields() { ISegment expected = new Gp1Segment { TypeOfBillCode = new CodedWithExceptions { Identifier = "1" }, RevenueCode = new CodedWithExceptions[] { new CodedWithExceptions { Identifier = "2" } }, OverallClaimDispositionCode = new CodedWithExceptions { Identifier = "3" }, OceEditsPerVisitCode = new CodedWithExceptions[] { new CodedWithExceptions { Identifier = "4" } }, OutlierCost = new CompositePrice { Price = new Money { Quantity = 5 } } }; ISegment actual = new Gp1Segment(); actual.FromDelimitedString("GP1|1|2|3|4|5"); expected.Should().BeEquivalentTo(actual); }