photoprism/internal/query/counts_test.go
2020-07-13 11:40:49 +02:00

17 lines
361 B
Go

package query
import (
"github.com/stretchr/testify/assert"
"testing"
)
func TestCounts_Refresh(t *testing.T) {
counts := Counts{Cameras: 0, Photos: 0}
assert.Equal(t, counts.Cameras, 0)
assert.Equal(t, counts.Photos, 0)
counts.Refresh()
assert.Greater(t, counts.Cameras, 0)
assert.Greater(t, counts.Photos, 0)
assert.Greater(t, counts.Albums, 0)
}