Change KL to kL, update specs for ML to kL change

This commit is contained in:
Rohan Mitchell
2014-07-17 16:16:08 +10:00
parent 58e6379e43
commit 989a14fa37
8 changed files with 10 additions and 10 deletions

View File

@@ -87,7 +87,7 @@ describe "Option Value Namer", ->
expect(namer.option_value_value_unit()).toEqual [100, unit]
it "generates values for all volume scales", ->
for units in [[0.001, 'mL'], [1.0, 'L'], [1000000.0, 'ML']]
for units in [[0.001, 'mL'], [1.0, 'L'], [1000.0, 'kL']]
[scale, unit] = units
p.variant_unit = 'volume'
p.variant_unit_scale = scale

View File

@@ -352,7 +352,7 @@ describe "AdminOrderMgmtCtrl", ->
expect(scope.getScale(1.2,"weight")).toEqual 1.0
expect(scope.getScale(1000,"weight")).toEqual 1000.0
expect(scope.getScale(0.0012,"volume")).toEqual 0.001
expect(scope.getScale(1001,"volume")).toEqual 1.0
expect(scope.getScale(1001,"volume")).toEqual 1000.0
it "returns the smallest unit available when value is smaller", ->
expect(scope.getScale(0.4,"weight")).toEqual 1
@@ -365,7 +365,7 @@ describe "AdminOrderMgmtCtrl", ->
expect(scope.getUnitName(1000000,"weight")).toEqual "T"
expect(scope.getUnitName(0.001,"volume")).toEqual "mL"
expect(scope.getUnitName(1,"volume")).toEqual "L"
expect(scope.getUnitName(1000000,"volume")).toEqual "ML"
expect(scope.getUnitName(1000,"volume")).toEqual "kL"
describe "managing pending changes", ->
dataSubmitter = pendingChangesService = null