< Summary

Information
Class: LGDXRobotCloud.Data.Entities.Trigger
Assembly: LGDXRobotCloud.Data
File(s): /builds/yukaitung/lgdxrobot2-cloud/LGDXRobotCloud.Data/Entities/Trigger.cs
Line coverage
100%
Covered lines: 9
Uncovered lines: 0
Coverable lines: 9
Total lines: 36
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
get_Id()100%11100%
get_Name()100%11100%
get_Url()100%11100%
get_HttpMethodId()100%11100%
get_Body()100%11100%
get_ApiKeyInsertLocationId()100%11100%
get_ApiKeyFieldName()100%11100%
get_ApiKey()100%11100%
get_ApiKeyId()100%11100%

File(s)

/builds/yukaitung/lgdxrobot2-cloud/LGDXRobotCloud.Data/Entities/Trigger.cs

#LineLine coverage
 1using System.ComponentModel.DataAnnotations;
 2using System.ComponentModel.DataAnnotations.Schema;
 3using Microsoft.EntityFrameworkCore;
 4
 5namespace LGDXRobotCloud.Data.Entities;
 6
 7[Table("Automation.Triggers")]
 8[Index(nameof(ApiKeyInsertLocationId))]
 9public class Trigger
 10{
 11  [Key]
 12  [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
 7313  public int Id { get; set; }
 14
 15  [MaxLength(50)]
 16  [Required]
 15417  public string Name { get; set; } = null!;
 18
 19  [MaxLength(200)]
 20  [Required]
 13021  public string Url { get; set; } = null!;
 22
 6923  public int HttpMethodId { get; set; }
 24
 4525  public string? Body { get; set; }
 26
 3927  public int? ApiKeyInsertLocationId { get; set; }
 28
 29  [MaxLength(50)]
 3930  public string? ApiKeyFieldName { get; set; } // Header name or Json name
 31
 32  [ForeignKey("ApiKeyId")]
 133  public ApiKey? ApiKey { get; set; }
 34
 3935  public int? ApiKeyId { get; set; }
 36}