push
github
45 of 49 new or added lines in 4 files covered. (91.84%)
17 existing lines in 2 files now uncovered.2088 of 3439 relevant lines covered (60.72%)
12.83 hits per line
| 1 |
package model
|
|
| 2 |
|
|
| 3 |
import (
|
|
| 4 |
"time"
|
|
| 5 |
|
|
| 6 |
"github.com/welovemedia/ffmate/v2/internal/dto"
|
|
| 7 |
"gorm.io/gorm"
|
|
| 8 |
) |
|
| 9 |
|
|
| 10 |
type WebhookExecution struct { |
|
| 11 |
CreatedAt time.Time |
|
| 12 |
UpdatedAt time.Time |
|
| 13 |
Request *dto.WebhookRequest `gorm:"json"`
|
|
| 14 |
Response *dto.WebhookResponse `gorm:"json"`
|
|
| 15 |
DeletedAt gorm.DeletedAt `gorm:"index"`
|
|
| 16 |
UUID string
|
|
| 17 |
Event dto.WebhookEvent |
|
| 18 |
URL string
|
|
| 19 |
ID uint `gorm:"primarykey"` |
|
| 20 |
} |
|
| 21 |
|
|
|
UNCOV
22
|
func (m *WebhookExecution) ToDTO() *dto.WebhookExecution {
|
× |
|
UNCOV
23
|
return &dto.WebhookExecution{
|
× |
|
UNCOV
24
|
UUID: m.UUID, |
× |
|
UNCOV
25
|
|
× |
|
UNCOV
26
|
Event: m.Event, |
× |
|
UNCOV
27
|
URL: m.URL, |
× |
|
UNCOV
28
|
|
× |
|
UNCOV
29
|
Request: m.Request, |
× |
|
UNCOV
30
|
Response: m.Response, |
× |
|
UNCOV
31
|
|
× |
|
UNCOV
32
|
CreatedAt: m.CreatedAt, |
× |
|
UNCOV
33
|
UpdatedAt: m.UpdatedAt, |
× |
|
UNCOV
34
|
} |
× |
|
UNCOV
35
|
} |
× |
| 36 |
|
|
| 37 |
func (WebhookExecution) TableName() string { |
38✔ |
| 38 |
return "webhookExecution" |
38✔ |
| 39 |
} |
38✔ |