smartenv/coverage/lcov-report/dist/smartenv.objectstorage.js.html

210 lines
11 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!doctype html>
<html lang="en">
<head>
<title>Code coverage report for dist/smartenv.objectstorage.js</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="../prettify.css" />
<link rel="stylesheet" href="../base.css" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type='text/css'>
.coverage-summary .sorter {
background-image: url(../sort-arrow-sprite.png);
}
</style>
</head>
<body>
<div class='wrapper'>
<div class='pad1'>
<h1>
<a href="../index.html">all files</a> / <a href="index.html">dist/</a> smartenv.objectstorage.js
</h1>
<div class='clearfix'>
<div class='fl pad1y space-right2'>
<span class="strong">66.67% </span>
<span class="quiet">Statements</span>
<span class='fraction'>16/24</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">58.33% </span>
<span class="quiet">Branches</span>
<span class='fraction'>7/12</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">83.33% </span>
<span class="quiet">Functions</span>
<span class='fraction'>5/6</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">72.73% </span>
<span class="quiet">Lines</span>
<span class='fraction'>16/22</span>
</div>
</div>
</div>
<div class='status-line medium'></div>
<pre><table class="coverage">
<tr><td class="line-count quiet">1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49</td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">6×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">2×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-yes">1×</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span></td><td class="text"><pre class="prettyprint lang-js">#!/usr/bin/env node
&nbsp;
/// &lt;reference path="typings/main.d.ts" /&gt;
var plugins = require("./smartenv.plugins");
exports.obs = {
add: function (paramNameArg, objectArg) {
<span class="missing-if-branch" title="if path not taken" >I</span>if (paramNameArg === void 0) { <span class="cstat-no" title="statement not covered" >paramNameArg = "undefined"; </span>}
<span class="missing-if-branch" title="if path not taken" >I</span>if (objectArg === void 0) { <span class="cstat-no" title="statement not covered" >objectArg = "undefined"; </span>}
<span class="missing-if-branch" title="if path not taken" >I</span>if (paramNameArg == "undefined") {
<span class="cstat-no" title="statement not covered" > plugins.beautylog.error("paramName is undefined");</span>
<span class="cstat-no" title="statement not covered" > return;</span>
}
<span class="missing-if-branch" title="if path not taken" >I</span>if (objectArg == "undefined") {
<span class="cstat-no" title="statement not covered" > plugins.beautylog.error("objectArg is undefined");</span>
}
if (typeof exports.obsItems[paramNameArg] === "undefined") {
exports.obsItems[paramNameArg] = objectArg;
}
else {
plugins.beautylog.error("object is already present, so add operation has failed.");
}
return exports.obsItems[paramNameArg];
},
replace: function (paramNameArg, objectArg) {
exports.obsItems[paramNameArg] = objectArg;
},
merge: function (paramNameArg, objectArg) {
<span class="missing-if-branch" title="else path not taken" >E</span>if (!(typeof exports.obsItems[paramNameArg] === "undefined")) {
exports.obsItems[paramNameArg] = plugins._.assign(exports.obsItems[paramNameArg], objectArg);
}
else {
<span class="cstat-no" title="statement not covered" > plugins.beautylog.error("object is not present, so there is nothing to merge");</span>
}
},
get: function (keyName) {
return exports.obsItems[keyName];
},
getAll: function () {
return exports.obsItems;
},
addComplete: <span class="fstat-no" title="function not covered" >function (itemsArg) {</span>
<span class="cstat-no" title="statement not covered" > exports.obsItems = plugins._.assign(exports.obsItems, itemsArg);</span>
<span class="cstat-no" title="statement not covered" > return exports.obsItems;</span>
}
};
exports.obsItems = {};
&nbsp;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0ZW52Lm9iamVjdHN0b3JhZ2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsMENBQTBDO0FBQzFDLElBQU8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hcmFtTmFtZUFyZ10gPSBwbHVnaW5zLl8uYXNzaWduKG9ic0l0ZW1zW3BhcmFtTmFtZUFyZ10sb2JqZWN0QXJnKTtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIHBsdWdpbnMuYmVhdXR5bG9nLmVycm9yKFwib2JqZWN0IGlzIG5vdCBwcmVzZW50LCBzbyB0aGVyZSBpcyBub3RoaW5nIHRvIG1lcmdlXCIpO1xuICAgICAgICB9XG4gICAgfSxcbiAgICBnZXQ6IGZ1bmN0aW9uKGtleU5hbWUpIHtcbiAgICAgICAgcmV0dXJuIG9ic0l0ZW1zW2tleU5hbWVdO1xuICAgIH0sXG4gICAgZ2V0QWxsOiBmdW5jdGlvbiAoKSB7XG4gICAgICAgIHJldHVybiBvYnNJdGVtcztcbiAgICB9LFxuICAgIGFkZENvbXBsZXRlOiBmdW5jdGlvbihpdGVtc0FyZykge1xuICAgICAgICBvYnNJdGVtcyA9IHBsdWdpbnMuXy5hc3NpZ24ob2JzSXRlbXMsaXRlbXNBcmcpO1xuICAgICAgICByZXR1cm4gb2JzSXRlbXM7XG4gICAgfVxufTtcbmV4cG9ydCB2YXIgb2JzSXRlbXM6YW55ID0ge307Il0sInNvdXJjZVJvb3QiOiIvc291cmNlLyJ9
&nbsp;</pre></td></tr>
</table></pre>
<div class='push'></div><!-- for sticky footer -->
</div><!-- /wrapper -->
<div class='footer quiet pad2 space-top1 center small'>
Code coverage
generated by <a href="http://istanbul-js.org/" target="_blank">istanbul</a> at Wed Feb 17 2016 21:43:50 GMT+0100 (CET)
</div>
</div>
<script src="../prettify.js"></script>
<script>
window.onload = function () {
if (typeof prettyPrint === 'function') {
prettyPrint();
}
};
</script>
<script src="../sorter.js"></script>
</body>
</html>