fix: flaky TestForcePublish
This commit is contained in:
parent
6de62411c6
commit
af45b299e7
@ -202,6 +202,12 @@ func publishDeal(t *testing.T, dp *DealPublisher, ctxCancelled bool, expired boo
|
|||||||
|
|
||||||
go func() {
|
go func() {
|
||||||
_, err := dp.Publish(pctx, deal)
|
_, err := dp.Publish(pctx, deal)
|
||||||
|
|
||||||
|
// If the test has completed just bail out without checking for errors
|
||||||
|
if ctx.Err() != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
if ctxCancelled || expired {
|
if ctxCancelled || expired {
|
||||||
require.Error(t, err)
|
require.Error(t, err)
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user