mirror of
https://github.com/go-vikunja/vikunja.git
synced 2026-03-12 01:59:34 -05:00
test: add OR-joined reminder filter regression test
Verify that OR-joined conditions on the same sub-table still produce separate EXISTS subqueries and match independently, as expected.
This commit is contained in:
@@ -1131,6 +1131,18 @@ func TestTaskCollection_ReadAll(t *testing.T) {
|
||||
want: []*Task{},
|
||||
wantErr: false,
|
||||
},
|
||||
{
|
||||
name: "filtered reminder dates with OR should match independently",
|
||||
fields: fields{
|
||||
Filter: "reminders > '2019-01-01T00:00:00+00:00' || reminders < '2018-09-01T00:00:00+00:00'",
|
||||
},
|
||||
args: defaultArgs,
|
||||
want: []*Task{
|
||||
task2, // has reminder at 2019-06-01 (> 2019-01-01)
|
||||
task47, // has reminder at 2019-03-01 (> 2019-01-01) and 2018-08-01 (< 2018-09-01)
|
||||
},
|
||||
wantErr: false,
|
||||
},
|
||||
{
|
||||
name: "filter in keyword",
|
||||
fields: fields{
|
||||
|
||||
Reference in New Issue
Block a user