Tests for the taxon filtering

This commit is contained in:
Will Marshall
2014-07-04 15:19:45 +10:00
parent f335b6a576
commit eb8f59d65b
11 changed files with 48 additions and 19 deletions

View File

@@ -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

View File

@@ -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: []
}
]