forked from Silverfish/proton-bridge
feat(GODT-2715): Add Unitary test for configStatus event.
This commit is contained in:
committed by
Romain Le Jeune
parent
f5af2afce5
commit
1f79e3b0a7
@ -45,6 +45,9 @@ func (*ConfigProgressBuilder) New(data *ConfigurationStatusData) ConfigProgressD
|
||||
}
|
||||
|
||||
func numberOfDay(now, prev time.Time) int {
|
||||
if now.IsZero() || prev.IsZero() {
|
||||
return 0
|
||||
}
|
||||
if now.Year() > prev.Year() {
|
||||
if now.YearDay() > prev.YearDay() {
|
||||
return 365 + (now.YearDay() - prev.YearDay())
|
||||
|
||||
Reference in New Issue
Block a user