< Summary - Combined Code Coverage

Information
Class: NLightning.Infrastructure.Persistence.SqlServer.Migrations.NLightningDbContextModelSnapshot
Assembly: NLightning.Infrastructure.Persistence.SqlServer
File(s): /home/runner/work/nlightning/nlightning/src/NLightning.Infrastructure.Persistence.SqlServer/Migrations/NLightningDbContextModelSnapshot.cs
Tag: 36_15743069263
Line coverage
0%
Covered lines: 0
Uncovered lines: 324
Coverable lines: 324
Total lines: 360
Line coverage: 0%
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
BuildModel(...)100%210%

File(s)

/home/runner/work/nlightning/nlightning/src/NLightning.Infrastructure.Persistence.SqlServer/Migrations/NLightningDbContextModelSnapshot.cs

#LineLine coverage
 1// <auto-generated />
 2using System;
 3using Microsoft.EntityFrameworkCore;
 4using Microsoft.EntityFrameworkCore.Infrastructure;
 5using Microsoft.EntityFrameworkCore.Metadata;
 6using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
 7using NLightning.Infrastructure.Persistence.Contexts;
 8
 9#nullable disable
 10
 11namespace NLightning.Infrastructure.Persistence.SqlServer.Migrations
 12{
 13    [DbContext(typeof(NLightningDbContext))]
 14    partial class NLightningDbContextModelSnapshot : ModelSnapshot
 15    {
 16        protected override void BuildModel(ModelBuilder modelBuilder)
 17        {
 18#pragma warning disable 612, 618
 019            modelBuilder
 020                .HasAnnotation("ProductVersion", "8.0.12")
 021                .HasAnnotation("Relational:MaxIdentifierLength", 128);
 22
 023            SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
 24
 025            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Bitcoin.BlockchainStateEntity", b =>
 026                {
 027                    b.Property<Guid>("Id")
 028                        .ValueGeneratedOnAdd()
 029                        .HasColumnType("uniqueidentifier");
 030
 031                    b.Property<DateTime>("LastProcessedAt")
 032                        .HasColumnType("datetime2");
 033
 034                    b.Property<byte[]>("LastProcessedBlockHash")
 035                        .IsRequired()
 036                        .HasColumnType("varbinary(32)");
 037
 038                    b.Property<long>("LastProcessedHeight")
 039                        .HasColumnType("bigint");
 040
 041                    b.HasKey("Id");
 042
 043                    b.ToTable("BlockchainStates");
 044                });
 45
 046            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Bitcoin.WatchedTransactionEntity", b =>
 047                {
 048                    b.Property<byte[]>("TransactionId")
 049                        .HasColumnType("varbinary(32)");
 050
 051                    b.Property<byte[]>("ChannelId")
 052                        .IsRequired()
 053                        .HasColumnType("varbinary(32)");
 054
 055                    b.Property<DateTime?>("CompletedAt")
 056                        .HasColumnType("datetime2");
 057
 058                    b.Property<DateTime>("CreatedAt")
 059                        .HasColumnType("datetime2");
 060
 061                    b.Property<long?>("FirstSeenAtHeight")
 062                        .HasColumnType("bigint");
 063
 064                    b.Property<long>("RequiredDepth")
 065                        .HasColumnType("bigint");
 066
 067                    b.Property<int?>("TransactionIndex")
 068                        .HasColumnType("int");
 069
 070                    b.HasKey("TransactionId");
 071
 072                    b.HasIndex("ChannelId");
 073
 074                    b.ToTable("WatchedTransactions");
 075                });
 76
 077            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelConfigEntity", b =>
 078                {
 079                    b.Property<byte[]>("ChannelId")
 080                        .HasColumnType("varbinary(32)");
 081
 082                    b.Property<long?>("ChannelReserveAmountSats")
 083                        .HasColumnType("bigint");
 084
 085                    b.Property<long>("FeeRatePerKwSatoshis")
 086                        .HasColumnType("bigint");
 087
 088                    b.Property<decimal>("HtlcMinimumMsat")
 089                        .HasColumnType("decimal(20,0)");
 090
 091                    b.Property<long>("LocalDustLimitAmountSats")
 092                        .HasColumnType("bigint");
 093
 094                    b.Property<byte[]>("LocalUpfrontShutdownScript")
 095                        .HasColumnType("varbinary(max)");
 096
 097                    b.Property<int>("MaxAcceptedHtlcs")
 098                        .HasColumnType("int");
 099
 0100                    b.Property<decimal>("MaxHtlcAmountInFlight")
 0101                        .HasColumnType("decimal(20,0)");
 0102
 0103                    b.Property<long>("MinimumDepth")
 0104                        .HasColumnType("bigint");
 0105
 0106                    b.Property<bool>("OptionAnchorOutputs")
 0107                        .HasColumnType("bit");
 0108
 0109                    b.Property<long>("RemoteDustLimitAmountSats")
 0110                        .HasColumnType("bigint");
 0111
 0112                    b.Property<byte[]>("RemoteUpfrontShutdownScript")
 0113                        .HasColumnType("varbinary(max)");
 0114
 0115                    b.Property<int>("ToSelfDelay")
 0116                        .HasColumnType("int");
 0117
 0118                    b.Property<byte>("UseScidAlias")
 0119                        .HasColumnType("tinyint");
 0120
 0121                    b.HasKey("ChannelId");
 0122
 0123                    b.ToTable("ChannelConfigs");
 0124                });
 125
 0126            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", b =>
 0127                {
 0128                    b.Property<byte[]>("ChannelId")
 0129                        .HasColumnType("varbinary(32)");
 0130
 0131                    b.Property<long>("FundingAmountSatoshis")
 0132                        .HasColumnType("bigint");
 0133
 0134                    b.Property<long>("FundingCreatedAtBlockHeight")
 0135                        .HasColumnType("bigint");
 0136
 0137                    b.Property<int>("FundingOutputIndex")
 0138                        .HasColumnType("int");
 0139
 0140                    b.Property<byte[]>("FundingTxId")
 0141                        .IsRequired()
 0142                        .HasColumnType("varbinary(32)");
 0143
 0144                    b.Property<bool>("IsInitiator")
 0145                        .HasColumnType("bit");
 0146
 0147                    b.Property<byte[]>("LastReceivedSignature")
 0148                        .HasColumnType("varbinary(64)");
 0149
 0150                    b.Property<byte[]>("LastSentSignature")
 0151                        .HasColumnType("varbinary(64)");
 0152
 0153                    b.Property<long>("LocalBalanceSatoshis")
 0154                        .HasColumnType("bigint");
 0155
 0156                    b.Property<decimal>("LocalNextHtlcId")
 0157                        .HasColumnType("decimal(20,0)");
 0158
 0159                    b.Property<decimal>("LocalRevocationNumber")
 0160                        .HasColumnType("decimal(20,0)");
 0161
 0162                    b.Property<byte[]>("PeerEntityNodeId")
 0163                        .HasColumnType("varbinary(33)");
 0164
 0165                    b.Property<long>("RemoteBalanceSatoshis")
 0166                        .HasColumnType("bigint");
 0167
 0168                    b.Property<decimal>("RemoteNextHtlcId")
 0169                        .HasColumnType("decimal(20,0)");
 0170
 0171                    b.Property<byte[]>("RemoteNodeId")
 0172                        .IsRequired()
 0173                        .HasColumnType("varbinary(32)");
 0174
 0175                    b.Property<decimal>("RemoteRevocationNumber")
 0176                        .HasColumnType("decimal(20,0)");
 0177
 0178                    b.Property<byte>("State")
 0179                        .HasColumnType("tinyint");
 0180
 0181                    b.Property<byte>("Version")
 0182                        .HasColumnType("tinyint");
 0183
 0184                    b.HasKey("ChannelId");
 0185
 0186                    b.HasIndex("PeerEntityNodeId");
 0187
 0188                    b.ToTable("Channels");
 0189                });
 190
 0191            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelKeySetEntity", b =>
 0192                {
 0193                    b.Property<byte[]>("ChannelId")
 0194                        .HasColumnType("varbinary(32)");
 0195
 0196                    b.Property<bool>("IsLocal")
 0197                        .HasColumnType("bit");
 0198
 0199                    b.Property<decimal>("CurrentPerCommitmentIndex")
 0200                        .HasColumnType("decimal(20,0)");
 0201
 0202                    b.Property<byte[]>("CurrentPerCommitmentPoint")
 0203                        .IsRequired()
 0204                        .HasColumnType("varbinary(33)");
 0205
 0206                    b.Property<byte[]>("DelayedPaymentBasepoint")
 0207                        .IsRequired()
 0208                        .HasColumnType("varbinary(33)");
 0209
 0210                    b.Property<byte[]>("FundingPubKey")
 0211                        .IsRequired()
 0212                        .HasColumnType("varbinary(33)");
 0213
 0214                    b.Property<byte[]>("HtlcBasepoint")
 0215                        .IsRequired()
 0216                        .HasColumnType("varbinary(33)");
 0217
 0218                    b.Property<long>("KeyIndex")
 0219                        .HasColumnType("bigint");
 0220
 0221                    b.Property<byte[]>("LastRevealedPerCommitmentSecret")
 0222                        .HasColumnType("varbinary(max)");
 0223
 0224                    b.Property<byte[]>("PaymentBasepoint")
 0225                        .IsRequired()
 0226                        .HasColumnType("varbinary(33)");
 0227
 0228                    b.Property<byte[]>("RevocationBasepoint")
 0229                        .IsRequired()
 0230                        .HasColumnType("varbinary(33)");
 0231
 0232                    b.HasKey("ChannelId", "IsLocal");
 0233
 0234                    b.ToTable("ChannelKeySets");
 0235                });
 236
 0237            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.HtlcEntity", b =>
 0238                {
 0239                    b.Property<byte[]>("ChannelId")
 0240                        .HasColumnType("varbinary(32)");
 0241
 0242                    b.Property<decimal>("HtlcId")
 0243                        .HasColumnType("decimal(20,0)");
 0244
 0245                    b.Property<byte>("Direction")
 0246                        .HasColumnType("tinyint");
 0247
 0248                    b.Property<byte[]>("AddMessageBytes")
 0249                        .IsRequired()
 0250                        .HasColumnType("varbinary(max)");
 0251
 0252                    b.Property<decimal>("AmountMsat")
 0253                        .HasColumnType("decimal(20,0)");
 0254
 0255                    b.Property<long>("CltvExpiry")
 0256                        .HasColumnType("bigint");
 0257
 0258                    b.Property<decimal>("ObscuredCommitmentNumber")
 0259                        .HasColumnType("decimal(20,0)");
 0260
 0261                    b.Property<byte[]>("PaymentHash")
 0262                        .IsRequired()
 0263                        .HasColumnType("varbinary(32)");
 0264
 0265                    b.Property<byte[]>("PaymentPreimage")
 0266                        .HasColumnType("varbinary(32)");
 0267
 0268                    b.Property<byte[]>("Signature")
 0269                        .HasColumnType("varbinary(max)");
 0270
 0271                    b.Property<byte>("State")
 0272                        .HasColumnType("tinyint");
 0273
 0274                    b.HasKey("ChannelId", "HtlcId", "Direction");
 0275
 0276                    b.ToTable("Htlcs");
 0277                });
 278
 0279            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Node.PeerEntity", b =>
 0280                {
 0281                    b.Property<byte[]>("NodeId")
 0282                        .HasColumnType("varbinary(33)");
 0283
 0284                    b.Property<string>("Host")
 0285                        .IsRequired()
 0286                        .HasColumnType("nvarchar(max)");
 0287
 0288                    b.Property<DateTime>("LastSeenAt")
 0289                        .HasColumnType("datetime2");
 0290
 0291                    b.Property<long>("Port")
 0292                        .HasColumnType("bigint");
 0293
 0294                    b.HasKey("NodeId");
 0295
 0296                    b.ToTable("Peers");
 0297                });
 298
 0299            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Bitcoin.WatchedTransactionEntity", b =>
 0300                {
 0301                    b.HasOne("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", null)
 0302                        .WithMany("WatchedTransactions")
 0303                        .HasForeignKey("ChannelId")
 0304                        .OnDelete(DeleteBehavior.Cascade)
 0305                        .IsRequired();
 0306                });
 307
 0308            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelConfigEntity", b =>
 0309                {
 0310                    b.HasOne("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", null)
 0311                        .WithOne("Config")
 0312                        .HasForeignKey("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelConfigEntity", "Ch
 0313                        .OnDelete(DeleteBehavior.Cascade)
 0314                        .IsRequired();
 0315                });
 316
 0317            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", b =>
 0318                {
 0319                    b.HasOne("NLightning.Infrastructure.Persistence.Entities.Node.PeerEntity", null)
 0320                        .WithMany("Channels")
 0321                        .HasForeignKey("PeerEntityNodeId");
 0322                });
 323
 0324            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelKeySetEntity", b =>
 0325                {
 0326                    b.HasOne("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", null)
 0327                        .WithMany("KeySets")
 0328                        .HasForeignKey("ChannelId")
 0329                        .OnDelete(DeleteBehavior.Cascade)
 0330                        .IsRequired();
 0331                });
 332
 0333            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.HtlcEntity", b =>
 0334                {
 0335                    b.HasOne("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", null)
 0336                        .WithMany("Htlcs")
 0337                        .HasForeignKey("ChannelId")
 0338                        .OnDelete(DeleteBehavior.Cascade)
 0339                        .IsRequired();
 0340                });
 341
 0342            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Channel.ChannelEntity", b =>
 0343                {
 0344                    b.Navigation("Config");
 0345
 0346                    b.Navigation("Htlcs");
 0347
 0348                    b.Navigation("KeySets");
 0349
 0350                    b.Navigation("WatchedTransactions");
 0351                });
 352
 0353            modelBuilder.Entity("NLightning.Infrastructure.Persistence.Entities.Node.PeerEntity", b =>
 0354                {
 0355                    b.Navigation("Channels");
 0356                });
 357#pragma warning restore 612, 618
 0358        }
 359    }
 360}