mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-12 23:27:48 +00:00
Tests for the taxon filtering
This commit is contained in:
@@ -28,3 +28,6 @@ describe 'filtering by shipping method', ->
|
||||
|
||||
it "filters to none", ->
|
||||
expect(filterByShippingMethod(objects, {pickup: false, delivery: false})).toBe objects
|
||||
|
||||
it "filters to none with empty", ->
|
||||
expect(filterByShippingMethod(objects, {})).toBe objects
|
||||
|
||||
@@ -3,6 +3,7 @@ describe 'filtering by taxons', ->
|
||||
objects = [
|
||||
{
|
||||
taxons: []
|
||||
supplied_taxons: []
|
||||
primary_taxon:
|
||||
name: "frogs"
|
||||
id: 1
|
||||
@@ -12,6 +13,7 @@ describe 'filtering by taxons', ->
|
||||
{name: "kittens", id: 2}
|
||||
{name: "puppies", id: 3}
|
||||
]
|
||||
supplied_taxons: []
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user