MM-31353: Fix flaky TestNoticeValidation/notice_with_specific_date_check (#20238)
We now generate the current time in UTC to avoid date transitions when running the tests at different local times. https://mattermost.atlassian.net/browse/MM-31353 ```release-note NONE ```
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
f08d65909f
Коммит
1f9657106b
@@ -360,7 +360,7 @@ func TestNoticeValidation(t *testing.T) {
|
|||||||
args: args{
|
args: args{
|
||||||
notice: &model.ProductNotice{
|
notice: &model.ProductNotice{
|
||||||
Conditions: model.Conditions{
|
Conditions: model.Conditions{
|
||||||
DisplayDate: model.NewString(fmt.Sprintf("= %sT00:00:00Z", time.Now().Format("2006-01-02"))),
|
DisplayDate: model.NewString(fmt.Sprintf("= %sT00:00:00Z", time.Now().UTC().Format("2006-01-02"))),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user