< Summary - Combined Code Coverage

Information
Class: NLightning.Domain.Protocol.Messages.ChannelReadyMessage
Assembly: NLightning.Domain
File(s): /home/runner/work/nlightning/nlightning/src/NLightning.Domain/Protocol/Messages/ChannelReadyMessage.cs
Tag: 30_15166811759
Line coverage
100%
Covered lines: 8
Uncovered lines: 0
Coverable lines: 8
Total lines: 35
Line coverage: 100%
Branch coverage
100%
Covered branches: 2
Total branches: 2
Branch coverage: 100%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_Payload()100%11100%
get_ShortChannelIdTlv()100%11100%
.ctor(...)100%22100%

File(s)

/home/runner/work/nlightning/nlightning/src/NLightning.Domain/Protocol/Messages/ChannelReadyMessage.cs

#LineLine coverage
 1namespace NLightning.Domain.Protocol.Messages;
 2
 3using Constants;
 4using Models;
 5using Payloads;
 6using Tlv;
 7
 8/// <summary>
 9/// Represents a channel_ready message.
 10/// </summary>
 11/// <remarks>
 12/// The channel_ready message indicates that the funding transaction has sufficient confirms for channel use.
 13/// The message type is 36.
 14/// </remarks>
 15public sealed class ChannelReadyMessage : BaseMessage
 16{
 17    /// <summary>
 18    /// The payload of the message.
 19    /// </summary>
 820    public new ChannelReadyPayload Payload { get => (ChannelReadyPayload)base.Payload; }
 21
 3222    public ShortChannelIdTlv? ShortChannelIdTlv { get; }
 23
 24    public ChannelReadyMessage(ChannelReadyPayload payload, ShortChannelIdTlv? shortChannelIdTlv = null)
 1625        : base(MessageTypes.CHANNEL_READY, payload)
 26    {
 1627        ShortChannelIdTlv = shortChannelIdTlv;
 28
 1629        if (ShortChannelIdTlv is not null)
 30        {
 831            Extension = new TlvStream();
 832            Extension.Add(ShortChannelIdTlv);
 33        }
 1634    }
 35}