< Summary

Information
Class: Syki.Back.Features.Academic.CreateNotification.UserNotificationConfig
Assembly: Back
File(s): /home/runner/work/syki/syki/Back/Features/Academic/CreateNotification/UserNotificationConfig.cs
Tag: 22_11348620282
Line coverage
100%
Covered lines: 9
Uncovered lines: 0
Coverable lines: 9
Total lines: 21
Line coverage: 100%
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
Configure(...)100%11100%

File(s)

/home/runner/work/syki/syki/Back/Features/Academic/CreateNotification/UserNotificationConfig.cs

#LineLine coverage
 1using Syki.Back.Features.Cross.CreateUser;
 2
 3namespace Syki.Back.Features.Academic.CreateNotification;
 4
 5public class UserNotificationConfig : IEntityTypeConfiguration<UserNotification>
 6{
 7    public void Configure(EntityTypeBuilder<UserNotification> userNotification)
 8    {
 29        userNotification.ToTable("users__notifications");
 10
 211        userNotification.HasKey(un => new { un.UserId, un.NotificationId });
 12
 213        userNotification.HasOne<SykiUser>()
 214            .WithMany()
 215            .HasForeignKey(un => un.UserId);
 16
 217        userNotification.HasOne(x => x.Notification)
 218            .WithMany(x => x.Users)
 219            .HasForeignKey(un => un.NotificationId);
 220    }
 21}