store: separate tests that need Store from those needing *store

This commit is contained in:
Anthony Romano
2017-08-15 10:54:02 -07:00
parent 8091be6e97
commit cab7572b00
4 changed files with 606 additions and 473 deletions

View File

@ -86,7 +86,11 @@ const (
)
func init() {
prometheus.MustRegister(readCounter)
if prometheus.Register(readCounter) != nil {
// Tests will try to double register sicne the tests use both
// store and store_test packages; ignore second attempts.
return
}
prometheus.MustRegister(writeCounter)
prometheus.MustRegister(expireCounter)
prometheus.MustRegister(watchRequests)