|
Last change
on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 12 days ago |
|
Fix frontend appearance
|
-
Property mode
set to
100644
|
|
File size:
478 bytes
|
| Line | |
|---|
| 1 | /*
|
|---|
| 2 | Copyright 2015, Yahoo Inc.
|
|---|
| 3 | Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms.
|
|---|
| 4 | */
|
|---|
| 5 | 'use strict';
|
|---|
| 6 |
|
|---|
| 7 | function getUniqueKey(pathname) {
|
|---|
| 8 | return pathname.replace(/[\\/]/g, '_');
|
|---|
| 9 | }
|
|---|
| 10 |
|
|---|
| 11 | function getOutput(cache) {
|
|---|
| 12 | return Object.values(cache).reduce(
|
|---|
| 13 | (output, { file, mappedCoverage }) => ({
|
|---|
| 14 | ...output,
|
|---|
| 15 | [file]: mappedCoverage
|
|---|
| 16 | }),
|
|---|
| 17 | {}
|
|---|
| 18 | );
|
|---|
| 19 | }
|
|---|
| 20 |
|
|---|
| 21 | module.exports = { getUniqueKey, getOutput };
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.