This repository has been archived by the owner on May 8, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Fix: Charge History Persister to cope with EndDateTime
being null
#1911
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
prtandrup
requested review from
Mech0z,
lasrinnil,
HenrikSommer,
jonasdmoeller,
x-platformcoder and
ShaBloze
as code owners
December 16, 2022 08:27
Codecov Report
@@ Coverage Diff @@
## main #1911 +/- ##
===========================================
+ Coverage 32.22% 84.36% +52.13%
===========================================
Files 24 461 +437
Lines 512 8198 +7686
Branches 23 23
===========================================
+ Hits 165 6916 +6751
- Misses 332 1138 +806
- Partials 15 144 +129
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
...Charges/source/GreenEnergyHub.Charges.Application/Charges/Factories/IChargeHistoryFactory.cs
Outdated
Show resolved
Hide resolved
...Charges/source/GreenEnergyHub.Charges.FunctionHost/Configuration/HealthCheckConfiguration.cs
Outdated
Show resolved
Hide resolved
Kudos, SonarCloud Quality Gate passed! |
HenrikSommer
approved these changes
Dec 16, 2022
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
When the
ChargeInformationOperationsAcceptedEvent
contains a brand new charge, theEndDateTime
isnull
.This was not anticipated and the
ChargeHistoryPersisterEndpoint
threw anArgumentNullException
.This PR now handles this scenario, by setting
EndDefault
whennull
through a newChargeHistoryFactory.cs
.Also, the service bus subscription failing has been fixed. Kudos @HenrikSommer for your great 👀
Also, I spotted an incorrect document type used in a builder, and changed it (unrelated to the bug).
References