Convert enterprise relationship permission to string presentation

This commit is contained in:
Rohan Mitchell
2014-08-25 13:27:01 +10:00
parent 70feef1256
commit b4e89ad2c0
2 changed files with 21 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
describe "enterprise relationships", ->
EnterpriseRelationships = null
enterprise_relationships = []
beforeEach ->
module "ofn.admin"
module ($provide) ->
$provide.value "enterprise_relationships", enterprise_relationships
null
beforeEach inject (_EnterpriseRelationships_) ->
EnterpriseRelationships = _EnterpriseRelationships_
it "presents permission names", ->
expect(EnterpriseRelationships.permission_presentation("add_products_to_order_cycle")).toEqual "can add products to order cycle from"
expect(EnterpriseRelationships.permission_presentation("manage_products")).toEqual "can manage the products of"