-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3ebd9dc
commit 1147de7
Showing
12 changed files
with
1,405 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
新增代码行,需要传入文件路径 | ||
|
||
```js | ||
const map = { | ||
"/path":{ | ||
add:[0,0,1], | ||
del:[0,0,1] | ||
} | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 5 additions & 2 deletions
7
packages/canyon-data/src/tests/genSummaryMapByCoverageMap.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,11 @@ | ||
import { expect, test } from 'vitest' | ||
import { genSummaryMapByCoverageMap } from '../index' | ||
import { genSummaryMapByCoverageMap,formatCoverageMap } from '../index' | ||
import mockSummaryData from './mock-summary-data.json' | ||
import mockCoverageData from './mock-coverage-data.json' | ||
|
||
// import formatCoverageMap from './in' | ||
test('generate summary map by coverage map', () => { | ||
|
||
console.log(formatCoverageMap(mockCoverageData,'/builds/canyon/canyon-demo')) | ||
|
||
expect(genSummaryMapByCoverageMap(mockCoverageData)).toMatchObject(mockSummaryData) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
const Th = () => { | ||
return ( | ||
<thead> | ||
<tr> | ||
<th | ||
data-col="file" | ||
data-fmt="html" | ||
data-html="true" | ||
className="file sorted" | ||
> | ||
File | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="pic" | ||
data-type="number" | ||
data-fmt="html" | ||
data-html="true" | ||
className="pic" | ||
> | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="statements" | ||
data-type="number" | ||
data-fmt="pct" | ||
className="pct" | ||
> | ||
Statements | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="statements_raw" | ||
data-type="number" | ||
data-fmt="html" | ||
className="abs" | ||
> | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="branches" | ||
data-type="number" | ||
data-fmt="pct" | ||
className="pct" | ||
> | ||
Branches | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="branches_raw" | ||
data-type="number" | ||
data-fmt="html" | ||
className="abs" | ||
> | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="functions" | ||
data-type="number" | ||
data-fmt="pct" | ||
className="pct" | ||
> | ||
Functions | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="functions_raw" | ||
data-type="number" | ||
data-fmt="html" | ||
className="abs" | ||
> | ||
<span className="sorter" /> | ||
</th> | ||
<th data-col="lines" data-type="number" data-fmt="pct" className="pct"> | ||
Lines | ||
<span className="sorter" /> | ||
</th> | ||
<th | ||
data-col="lines_raw" | ||
data-type="number" | ||
data-fmt="html" | ||
className="abs" | ||
> | ||
<span className="sorter" /> | ||
</th> | ||
</tr> | ||
</thead> | ||
); | ||
}; | ||
|
||
export default Th; |
Oops, something went wrong.