< Summary

Information
Class: EHonda.KicktippAi.Core.PersistedMatchOutcome
Assembly: EHonda.KicktippAi.Core
File(s): /home/runner/work/KicktippAi/KicktippAi/src/Core/MatchOutcomes.cs
Line coverage
7%
Covered lines: 1
Uncovered lines: 13
Coverable lines: 14
Total lines: 50
Line coverage: 7.1%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%11100%
.ctor(...)100%210%
get_CommunityContext()100%210%
set_CommunityContext(...)100%210%
get_Competition()100%210%
set_Competition(...)100%210%
get_HomeTeam()100%210%
set_HomeTeam(...)100%210%
get_AwayTeam()100%210%
set_AwayTeam(...)100%210%
get_StartsAt()100%210%
set_StartsAt(...)100%210%
get_Matchday()100%210%
set_Matchday(...)100%210%
get_HomeGoals()100%210%
set_HomeGoals(...)100%210%
get_AwayGoals()100%210%
set_AwayGoals(...)100%210%
get_Availability()100%210%
set_Availability(...)100%210%
get_TippSpielId()100%210%
set_TippSpielId(...)100%210%
get_CreatedAt()100%210%
set_CreatedAt(...)100%210%
get_UpdatedAt()100%210%
set_UpdatedAt(...)100%210%
get_HasOutcome()100%210%

File(s)

/home/runner/work/KicktippAi/KicktippAi/src/Core/MatchOutcomes.cs

#LineLine coverage
 1using NodaTime;
 2
 3namespace EHonda.KicktippAi.Core;
 4
 5public enum MatchOutcomeAvailability
 6{
 7    Pending,
 8    Completed
 9}
 10
 11public enum MatchOutcomeWriteDisposition
 12{
 13    Created,
 14    Updated,
 15    Unchanged
 16}
 17
 18public record CollectedMatchOutcome(
 19    string HomeTeam,
 20    string AwayTeam,
 21    ZonedDateTime StartsAt,
 22    int Matchday,
 23    int? HomeGoals,
 24    int? AwayGoals,
 25    MatchOutcomeAvailability Availability,
 26    string? TippSpielId = null)
 27{
 28    public bool HasOutcome => Availability == MatchOutcomeAvailability.Completed;
 29}
 30
 131public record PersistedMatchOutcome(
 032    string CommunityContext,
 033    string Competition,
 034    string HomeTeam,
 035    string AwayTeam,
 036    ZonedDateTime StartsAt,
 037    int Matchday,
 038    int? HomeGoals,
 039    int? AwayGoals,
 040    MatchOutcomeAvailability Availability,
 041    string? TippSpielId,
 042    DateTimeOffset CreatedAt,
 043    DateTimeOffset UpdatedAt)
 44{
 045    public bool HasOutcome => Availability == MatchOutcomeAvailability.Completed;
 46}
 47
 48public record MatchOutcomeUpsertResult(
 49    MatchOutcomeWriteDisposition Disposition,
 50    PersistedMatchOutcome Outcome);