photoprism/pkg/unix/time_test.go
Michael Mayer 305e7bac68 OAuth2: Refactor "client add" and "client mod" CLI commands #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-29 13:54:50 +01:00

17 lines
298 B
Go

package unix
import (
"testing"
"time"
"github.com/stretchr/testify/assert"
)
func TestTime(t *testing.T) {
result := Time()
assert.Greater(t, result, int64(1706521797))
assert.GreaterOrEqual(t, result, time.Now().UTC().Unix())
assert.LessOrEqual(t, result, time.Now().UTC().Unix()+2)
}