Commit 9c36ee22 by Patrick O'Carroll Committed by Torkel Ödegaard

changed m3 and dm3 to fixedUnit, fixes #10920 (#10944)

parent f47542db
......@@ -348,3 +348,10 @@ describe('duration', function() {
expect(str).toBe('1 year, 2 months, 0 weeks, 3 days, 4 hours, 5 minutes, 6 seconds, 7 milliseconds');
});
});
describe('volume', function() {
it('1000m3', function() {
var str = kbn.valueFormats['m3'](1000, 1, null);
expect(str).toBe('1000.0 m3');
});
});
......@@ -547,8 +547,8 @@ kbn.valueFormats.accG = kbn.formatBuilders.fixedUnit('g');
// Volume
kbn.valueFormats.litre = kbn.formatBuilders.decimalSIPrefix('L');
kbn.valueFormats.mlitre = kbn.formatBuilders.decimalSIPrefix('L', -1);
kbn.valueFormats.m3 = kbn.formatBuilders.decimalSIPrefix('m3');
kbn.valueFormats.dm3 = kbn.formatBuilders.decimalSIPrefix('dm3');
kbn.valueFormats.m3 = kbn.formatBuilders.fixedUnit('m3');
kbn.valueFormats.dm3 = kbn.formatBuilders.fixedUnit('dm3');
kbn.valueFormats.gallons = kbn.formatBuilders.fixedUnit('gal');
// Flow
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment