index.html 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350
  1. <!doctype html>
  2. <html lang="en">
  3. <head>
  4. <title>Code coverage report for All files</title>
  5. <meta charset="utf-8">
  6. <link rel="stylesheet" href="prettify.css">
  7. <style>
  8. body, html {
  9. margin:0; padding: 0;
  10. }
  11. body {
  12. font-family: Helvetica Neue, Helvetica,Arial;
  13. font-size: 10pt;
  14. }
  15. div.header, div.footer {
  16. background: #eee;
  17. padding: 1em;
  18. }
  19. div.header {
  20. z-index: 100;
  21. position: fixed;
  22. top: 0;
  23. border-bottom: 1px solid #666;
  24. width: 100%;
  25. }
  26. div.footer {
  27. border-top: 1px solid #666;
  28. }
  29. div.body {
  30. margin-top: 10em;
  31. }
  32. div.meta {
  33. font-size: 90%;
  34. text-align: center;
  35. }
  36. h1, h2, h3 {
  37. font-weight: normal;
  38. }
  39. h1 {
  40. font-size: 12pt;
  41. }
  42. h2 {
  43. font-size: 10pt;
  44. }
  45. pre {
  46. font-family: Consolas, Menlo, Monaco, monospace;
  47. margin: 0;
  48. padding: 0;
  49. line-height: 14px;
  50. font-size: 14px;
  51. -moz-tab-size: 2;
  52. -o-tab-size: 2;
  53. tab-size: 2;
  54. }
  55. div.path { font-size: 110%; }
  56. div.path a:link, div.path a:visited { color: #000; }
  57. table.coverage { border-collapse: collapse; margin:0; padding: 0 }
  58. table.coverage td {
  59. margin: 0;
  60. padding: 0;
  61. color: #111;
  62. vertical-align: top;
  63. }
  64. table.coverage td.line-count {
  65. width: 50px;
  66. text-align: right;
  67. padding-right: 5px;
  68. }
  69. table.coverage td.line-coverage {
  70. color: #777 !important;
  71. text-align: right;
  72. border-left: 1px solid #666;
  73. border-right: 1px solid #666;
  74. }
  75. table.coverage td.text {
  76. }
  77. table.coverage td span.cline-any {
  78. display: inline-block;
  79. padding: 0 5px;
  80. width: 40px;
  81. }
  82. table.coverage td span.cline-neutral {
  83. background: #eee;
  84. }
  85. table.coverage td span.cline-yes {
  86. background: #b5d592;
  87. color: #999;
  88. }
  89. table.coverage td span.cline-no {
  90. background: #fc8c84;
  91. }
  92. .cstat-yes { color: #111; }
  93. .cstat-no { background: #fc8c84; color: #111; }
  94. .fstat-no { background: #ffc520; color: #111 !important; }
  95. .cbranch-no { background: yellow !important; color: #111; }
  96. .cstat-skip { background: #ddd; color: #111; }
  97. .fstat-skip { background: #ddd; color: #111 !important; }
  98. .cbranch-skip { background: #ddd !important; color: #111; }
  99. .missing-if-branch {
  100. display: inline-block;
  101. margin-right: 10px;
  102. position: relative;
  103. padding: 0 4px;
  104. background: black;
  105. color: yellow;
  106. }
  107. .skip-if-branch {
  108. display: none;
  109. margin-right: 10px;
  110. position: relative;
  111. padding: 0 4px;
  112. background: #ccc;
  113. color: white;
  114. }
  115. .missing-if-branch .typ, .skip-if-branch .typ {
  116. color: inherit !important;
  117. }
  118. .entity, .metric { font-weight: bold; }
  119. .metric { display: inline-block; border: 1px solid #333; padding: 0.3em; background: white; }
  120. .metric small { font-size: 80%; font-weight: normal; color: #666; }
  121. div.coverage-summary table { border-collapse: collapse; margin: 3em; font-size: 110%; }
  122. div.coverage-summary td, div.coverage-summary table th { margin: 0; padding: 0.25em 1em; border-top: 1px solid #666; border-bottom: 1px solid #666; }
  123. div.coverage-summary th { text-align: left; border: 1px solid #666; background: #eee; font-weight: normal; }
  124. div.coverage-summary th.file { border-right: none !important; }
  125. div.coverage-summary th.pic { border-left: none !important; text-align: right; }
  126. div.coverage-summary th.pct { border-right: none !important; }
  127. div.coverage-summary th.abs { border-left: none !important; text-align: right; }
  128. div.coverage-summary td.pct { text-align: right; border-left: 1px solid #666; }
  129. div.coverage-summary td.abs { text-align: right; font-size: 90%; color: #444; border-right: 1px solid #666; }
  130. div.coverage-summary td.file { text-align: right; border-left: 1px solid #666; white-space: nowrap; }
  131. div.coverage-summary td.pic { min-width: 120px !important; }
  132. div.coverage-summary a:link { text-decoration: none; color: #000; }
  133. div.coverage-summary a:visited { text-decoration: none; color: #333; }
  134. div.coverage-summary a:hover { text-decoration: underline; }
  135. div.coverage-summary tfoot td { border-top: 1px solid #666; }
  136. div.coverage-summary .yui3-datatable-sort-indicator, div.coverage-summary .dummy-sort-indicator {
  137. height: 10px;
  138. width: 7px;
  139. display: inline-block;
  140. margin-left: 0.5em;
  141. }
  142. div.coverage-summary .yui3-datatable-sort-indicator {
  143. background: url("https://yui-s.yahooapis.com/3.6.0/build/datatable-sort/assets/skins/sam/sort-arrow-sprite.png") no-repeat scroll 0 0 transparent;
  144. }
  145. div.coverage-summary .yui3-datatable-sorted .yui3-datatable-sort-indicator {
  146. background-position: 0 -20px;
  147. }
  148. div.coverage-summary .yui3-datatable-sorted-desc .yui3-datatable-sort-indicator {
  149. background-position: 0 -10px;
  150. }
  151. .high { background: #b5d592 !important; }
  152. .medium { background: #ffe87c !important; }
  153. .low { background: #fc8c84 !important; }
  154. span.cover-fill, span.cover-empty {
  155. display:inline-block;
  156. border:1px solid #444;
  157. background: white;
  158. height: 12px;
  159. }
  160. span.cover-fill {
  161. background: #ccc;
  162. border-right: 1px solid #444;
  163. }
  164. span.cover-empty {
  165. background: white;
  166. border-left: none;
  167. }
  168. span.cover-full {
  169. border-right: none !important;
  170. }
  171. pre.prettyprint {
  172. border: none !important;
  173. padding: 0 !important;
  174. margin: 0 !important;
  175. }
  176. .com { color: #999 !important; }
  177. .ignore-none { color: #999; font-weight: normal; }
  178. </style>
  179. </head>
  180. <body>
  181. <div class="header high">
  182. <h1>Code coverage report for <span class="entity">All files</span></h1>
  183. <h2>
  184. Statements: <span class="metric">82.29% <small>(1385 / 1683)</small></span> &nbsp;&nbsp;&nbsp;&nbsp;
  185. Branches: <span class="metric">70.61% <small>(793 / 1123)</small></span> &nbsp;&nbsp;&nbsp;&nbsp;
  186. Functions: <span class="metric">83.48% <small>(288 / 345)</small></span> &nbsp;&nbsp;&nbsp;&nbsp;
  187. Lines: <span class="metric">82.5% <small>(1377 / 1669)</small></span> &nbsp;&nbsp;&nbsp;&nbsp;
  188. Ignored: <span class="metric"><span class="ignore-none">none</span></span> &nbsp;&nbsp;&nbsp;&nbsp;
  189. </h2>
  190. <div class="path"></div>
  191. </div>
  192. <div class="body">
  193. <div class="coverage-summary">
  194. <table>
  195. <thead>
  196. <tr>
  197. <th data-col="file" data-fmt="html" data-html="true" class="file">File</th>
  198. <th data-col="pic" data-type="number" data-fmt="html" data-html="true" class="pic"></th>
  199. <th data-col="statements" data-type="number" data-fmt="pct" class="pct">Statements</th>
  200. <th data-col="statements_raw" data-type="number" data-fmt="html" class="abs"></th>
  201. <th data-col="branches" data-type="number" data-fmt="pct" class="pct">Branches</th>
  202. <th data-col="branches_raw" data-type="number" data-fmt="html" class="abs"></th>
  203. <th data-col="functions" data-type="number" data-fmt="pct" class="pct">Functions</th>
  204. <th data-col="functions_raw" data-type="number" data-fmt="html" class="abs"></th>
  205. <th data-col="lines" data-type="number" data-fmt="pct" class="pct">Lines</th>
  206. <th data-col="lines_raw" data-type="number" data-fmt="html" class="abs"></th>
  207. </tr>
  208. </thead>
  209. <tbody><tr>
  210. <td class="file high" data-value="core/"><a href="core/index.html">core/</a></td>
  211. <td data-value="82.29" class="pic high"><span class="cover-fill" style="width: 82px;"></span><span class="cover-empty" style="width:18px;"></span></td>
  212. <td data-value="82.29" class="pct high">82.29%</td>
  213. <td data-value="1683" class="abs high">(1385&nbsp;/&nbsp;1683)</td>
  214. <td data-value="70.61" class="pct medium">70.61%</td>
  215. <td data-value="1123" class="abs medium">(793&nbsp;/&nbsp;1123)</td>
  216. <td data-value="83.48" class="pct high">83.48%</td>
  217. <td data-value="345" class="abs high">(288&nbsp;/&nbsp;345)</td>
  218. <td data-value="82.5" class="pct high">82.5%</td>
  219. <td data-value="1669" class="abs high">(1377&nbsp;/&nbsp;1669)</td>
  220. </tr>
  221. </tbody>
  222. </table>
  223. </div>
  224. </div>
  225. <div class="footer">
  226. <div class="meta">Generated by <a href="http://istanbul-js.org/" target="_blank">istanbul</a> at Sun Nov 16 2014 12:08:33 GMT-0800 (PST)</div>
  227. </div>
  228. <script src="prettify.js"></script>
  229. <script src="https://yui-s.yahooapis.com/3.6.0/build/yui/yui-min.js"></script>
  230. <script>
  231. YUI().use('datatable', function (Y) {
  232. var formatters = {
  233. pct: function (o) {
  234. o.className += o.record.get('classes')[o.column.key];
  235. try {
  236. return o.value.toFixed(2) + '%';
  237. } catch (ex) { return o.value + '%'; }
  238. },
  239. html: function (o) {
  240. o.className += o.record.get('classes')[o.column.key];
  241. return o.record.get(o.column.key + '_html');
  242. }
  243. },
  244. defaultFormatter = function (o) {
  245. o.className += o.record.get('classes')[o.column.key];
  246. return o.value;
  247. };
  248. function getColumns(theadNode) {
  249. var colNodes = theadNode.all('tr th'),
  250. cols = [],
  251. col;
  252. colNodes.each(function (colNode) {
  253. col = {
  254. key: colNode.getAttribute('data-col'),
  255. label: colNode.get('innerHTML') || ' ',
  256. sortable: !colNode.getAttribute('data-nosort'),
  257. className: colNode.getAttribute('class'),
  258. type: colNode.getAttribute('data-type'),
  259. allowHTML: colNode.getAttribute('data-html') === 'true' || colNode.getAttribute('data-fmt') === 'html'
  260. };
  261. col.formatter = formatters[colNode.getAttribute('data-fmt')] || defaultFormatter;
  262. cols.push(col);
  263. });
  264. return cols;
  265. }
  266. function getRowData(trNode, cols) {
  267. var tdNodes = trNode.all('td'),
  268. i,
  269. row = { classes: {} },
  270. node,
  271. name;
  272. for (i = 0; i < cols.length; i += 1) {
  273. name = cols[i].key;
  274. node = tdNodes.item(i);
  275. row[name] = node.getAttribute('data-value') || node.get('innerHTML');
  276. row[name + '_html'] = node.get('innerHTML');
  277. row.classes[name] = node.getAttribute('class');
  278. //Y.log('Name: ' + name + '; Value: ' + row[name]);
  279. if (cols[i].type === 'number') { row[name] = row[name] * 1; }
  280. }
  281. //Y.log(row);
  282. return row;
  283. }
  284. function getData(tbodyNode, cols) {
  285. var data = [];
  286. tbodyNode.all('tr').each(function (trNode) {
  287. data.push(getRowData(trNode, cols));
  288. });
  289. return data;
  290. }
  291. function replaceTable(node) {
  292. if (!node) { return; }
  293. var cols = getColumns(node.one('thead')),
  294. data = getData(node.one('tbody'), cols),
  295. table,
  296. parent = node.get('parentNode');
  297. table = new Y.DataTable({
  298. columns: cols,
  299. data: data,
  300. sortBy: 'file'
  301. });
  302. parent.set('innerHTML', '');
  303. table.render(parent);
  304. }
  305. Y.on('domready', function () {
  306. replaceTable(Y.one('div.coverage-summary table'));
  307. if (typeof prettyPrint === 'function') {
  308. prettyPrint();
  309. }
  310. });
  311. });
  312. </script>
  313. </body>
  314. </html>