Skip to content

Commit

Permalink
split quality for ebix and cim
Browse files Browse the repository at this point in the history
  • Loading branch information
MWO1024 committed Dec 20, 2024
1 parent 4563ee9 commit e179fff
Showing 1 changed file with 24 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,30 @@ public async Task Successfully_parsed(DocumentFormat format, Stream message)
energyObservation.Should().NotBeNull();
energyObservation.Position.Should().Be(position.ToString());
energyObservation.EnergyQuantity.Should().NotBeEmpty();
energyObservation.QuantityQuality.Should()
.Match(quality => quality == null || quality == "E01" || quality == "56" || quality == "A03" || quality == "A02" || quality == "A05");

if (format != DocumentFormat.Ebix)
{
energyObservation.QuantityQuality.Should()
.Match(
quality => quality == null
|| quality == "A01"
|| quality == "A02"
|| quality == "A03"
|| quality == "A04"
|| quality == "A05"
|| quality == "A06");
}
else
{
energyObservation.QuantityQuality.Should()
.Match(
quality => quality == null
|| quality == "56"
|| quality == "D01"
|| quality == "36"
|| quality == "E01");
}

position++;
}
}
Expand Down

0 comments on commit e179fff

Please sign in to comment.