alecthomas / alecthomas/assert

fail to equal time.Time

Aperta
#9 1 commento 1 reazione 0 assegnatari Vedi su GitHub
Lingua principale
Go
Stelle
195
Fork
16
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Given two times that are equal using their [`.Equal()`](https://pkg.go.dev/time#Time.Equal) method, they fail using `assert.Equal()`.

## Proposed solution

Instead of using `reflect.DeepEqual()`, first check if we are asserting times, and then use their [`.Equal()`](https://pkg.go.dev/time#Time.Equal) method.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.