@buildingsblock/core
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -246,3 +246,5 @@ "use strict"; | ||
}); | ||
return (0, _utils.toFixed)((0, _utils.average)(metrics), 2); | ||
return (0, _utils.toFixed)((0, _utils.average)(metrics.filter(function (x) { | ||
return x.toNumber() !== Infinity; | ||
})), 2); | ||
}; | ||
@@ -265,3 +267,5 @@ | ||
}); | ||
return (0, _utils.toFixed)((0, _utils.average)(metrics), 2); | ||
return (0, _utils.toFixed)((0, _utils.average)(metrics.filter(function (x) { | ||
return x.toNumber() !== Infinity; | ||
})), 2); | ||
}; | ||
@@ -268,0 +272,0 @@ |
{ | ||
"name": "@buildingsblock/core", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "Core code base for Eli", | ||
@@ -5,0 +5,0 @@ "main": "./lib/index.js", |
import test from 'ava' | ||
import { data } from '../data' | ||
import { | ||
@@ -249,3 +251,3 @@ calcRepairAndMaintenanceBudgetPerSquareFoot, | ||
test.only('calcAverageContingencyReserveFundPerOperatingBudget', (t) => { | ||
test('calcAverageContingencyReserveFundPerOperatingBudget', (t) => { | ||
const stratas = [ | ||
@@ -341,1 +343,10 @@ { | ||
}) | ||
test.only('calcAverageContingencyReserveFundContributionsPerOperatingBudget_realdata', (t) => { | ||
const stratas = data | ||
const result = calcAverageContingencyReserveFundContributionsPerOperatingBudget(stratas) | ||
t.is(result, 0.11, 'should return average budget per sqft for past year') | ||
}) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
398276
15
1208