Display products in table

This commit is contained in:
Rohan Mitchell
2014-11-20 12:28:26 +11:00
parent 7069b30e71
commit 58fdc48b9f
9 changed files with 53 additions and 7 deletions

View File

@@ -2,13 +2,15 @@ describe "OverrideVariantsCtrl", ->
ctrl = null
scope = null
hubs = [{id: 1, name: 'Hub'}]
producers = [{id: 2, name: 'Producer'}]
products = [{id: 1, name: 'Product'}]
beforeEach ->
module 'ofn.admin'
scope = {}
inject ($controller)->
ctrl = $controller 'AdminOverrideVariantsCtrl', {$scope: scope, hubs: hubs}
inject ($controller, Indexer) ->
ctrl = $controller 'AdminOverrideVariantsCtrl', {$scope: scope, Indexer: Indexer, hubs: hubs, producers: producers, products: products}
it "initialises the hub list and the chosen hub", ->
expect(scope.hubs).toEqual hubs