Fix missing date filter (#2434)

This commit is contained in:
WithoutPants
2022-03-29 06:45:46 +11:00
committed by GitHub
parent a2c611f90d
commit 02ee791796
6 changed files with 32 additions and 5 deletions

View File

@@ -6,6 +6,7 @@ package sqlite_test
import (
"database/sql"
"fmt"
"math"
"regexp"
"strconv"
"testing"
@@ -931,7 +932,8 @@ func TestSceneQueryIsMissingDate(t *testing.T) {
scenes := queryScene(t, sqb, &sceneFilter, nil)
assert.True(t, len(scenes) > 0)
// three in four scenes have no date
assert.Len(t, scenes, int(math.Ceil(float64(totalScenes)/4*3)))
// ensure date is null, empty or "0001-01-01"
for _, scene := range scenes {