2020-01-28 21:02:52 +01:00
|
|
|
package query
|
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
2020-05-08 15:41:01 +02:00
|
|
|
"github.com/stretchr/testify/assert"
|
2020-01-28 21:02:52 +01:00
|
|
|
)
|
|
|
|
|
2020-05-08 15:41:01 +02:00
|
|
|
func TestGetMomentsTime(t *testing.T) {
|
2020-01-28 21:02:52 +01:00
|
|
|
t.Run("result found", func(t *testing.T) {
|
2020-05-08 15:41:01 +02:00
|
|
|
result, err := GetMomentsTime()
|
2020-01-28 21:02:52 +01:00
|
|
|
|
|
|
|
assert.Nil(t, err)
|
|
|
|
assert.Equal(t, 2790, result[0].PhotoYear)
|
|
|
|
assert.Equal(t, 2, result[0].Count)
|
|
|
|
})
|
|
|
|
}
|