6e6051b172
We have migrated all of the satellites and we shouldn't keep dead-code around. Change-Id: I539d6766cfafa2f278ff7767ceb2d39f6777ace3
25 lines
544 B
Go
25 lines
544 B
Go
// Copyright (C) 2021 Storj Labs, Inc.
|
|
// See LICENSE for copying information.
|
|
|
|
package metabase_test
|
|
|
|
import (
|
|
"testing"
|
|
"time"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
|
|
"storj.io/common/testcontext"
|
|
"storj.io/storj/satellite/metabase"
|
|
"storj.io/storj/satellite/metabase/metabasetest"
|
|
)
|
|
|
|
func TestNow(t *testing.T) {
|
|
metabasetest.Run(t, func(ctx *testcontext.Context, t *testing.T, db *metabase.DB) {
|
|
sysnow := time.Now()
|
|
now, err := db.Now(ctx)
|
|
require.NoError(t, err)
|
|
require.WithinDuration(t, sysnow, now, 5*time.Second)
|
|
})
|
|
}
|