Skip to content

Commit

Permalink
add more test cases for filtering by owner or organization name
Browse files Browse the repository at this point in the history
  • Loading branch information
RuthShryock committed Dec 20, 2024
1 parent af046a7 commit e4e029f
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions jsapp/js/projects/projectViews/utils.tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,18 @@ describe('projectViewsUtils', () => {
'(search_field__owner_username__icontains:"foo" ' +
'OR search_field__organization_name__icontains:"foo")',
},
{
in: {fieldName: 'ownerUsername', condition: 'is', value: 'foo'},
out:
'(search_field__owner_username__iexact:"foo" ' +
'OR search_field__organization_name__iexact:"foo")',
},
{
in: {fieldName: 'ownerUsername', condition: 'doesNotContain', value: 'foo'},
out:
'NOT (search_field__owner_username__icontains:"foo" ' +
'OR NOT search_field__organization_name__icontains:"foo")',
},
{
in: {fieldName: 'ownerFullName', condition: 'endsWith', value: 'foo'},
out: 'owner__extra_details__data__name__iendswith:"foo"',
Expand Down

0 comments on commit e4e029f

Please sign in to comment.