monocart-coverage-reports 2.9.0 → 2.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1021,8 +1021,9 @@ const coverageOptions = {
1021
1021
  - Github actions:
1022
1022
  ```yml
1023
1023
  - name: Codecov
1024
- uses: codecov/codecov-action@v3
1024
+ uses: codecov/codecov-action@v4
1025
1025
  with:
1026
+ token: ${{ secrets.CODECOV_TOKEN }}
1026
1027
  files: ./coverage-reports/codecov.json
1027
1028
  ```
1028
1029
 
package/README.zh-Hans.md CHANGED
@@ -1025,8 +1025,9 @@ const coverageOptions = {
1025
1025
  - Github actions example:
1026
1026
  ```yml
1027
1027
  - name: Codecov
1028
- uses: codecov/codecov-action@v3
1028
+ uses: codecov/codecov-action@v4
1029
1029
  with:
1030
+ token: ${{ secrets.CODECOV_TOKEN }}
1030
1031
  files: ./coverage-reports/codecov.json
1031
1032
  ```
1032
1033
 
package/lib/cli.js CHANGED
@@ -3,10 +3,8 @@
3
3
  const path = require('path');
4
4
  const EC = require('eight-colors');
5
5
 
6
- const {
7
- foregroundChild,
8
- program
9
- } = require('./packages/monocart-coverage-cli.js');
6
+ const { program } = require('commander');
7
+ const { foregroundChild } = require('foreground-child');
10
8
 
11
9
  const MCR = require('./index.js');
12
10
  const Util = require('./utils/util.js');
@@ -1,6 +1,6 @@
1
- const {
2
- acorn, acornLoose, parseCss
3
- } = require('../packages/monocart-coverage-vendor.js');
1
+ const acorn = require('acorn');
2
+ const acornLoose = require('acorn-loose');
3
+ const { parseCss } = require('../packages/monocart-coverage-vendor.js');
4
4
  const Util = require('../utils/util.js');
5
5
 
6
6
  const { collectAstInfo } = require('./ast-visitor.js');
@@ -17,7 +17,9 @@ const {
17
17
  sortRanges, dedupeCountRanges, mergeRangesWith
18
18
  } = require('../utils/dedupe.js');
19
19
  const { getSourceType, initSourceMapSourcesPath } = require('../utils/source-path.js');
20
- const { decode, minimatch } = require('../packages/monocart-coverage-vendor.js');
20
+
21
+ const { decode } = require('@jridgewell/sourcemap-codec');
22
+ const { minimatch } = require('minimatch');
21
23
 
22
24
  const InfoBranch = require('./info-branch.js');
23
25
  const InfoFunction = require('./info-function.js');
@@ -1,4 +1,4 @@
1
- const { diff } = require('../packages/monocart-coverage-vendor');
1
+ const diffSequence = require('diff-sequences').default;
2
2
  const Util = require('../utils/util.js');
3
3
  const EC = Util.EC;
4
4
 
@@ -79,7 +79,7 @@ const alignText = (gt, ot, info) => {
79
79
  // console.log(ol);
80
80
 
81
81
  const commonItems = [];
82
- diff(gl.length, ol.length, (gi, oi) => {
82
+ diffSequence(gl.length, ol.length, (gi, oi) => {
83
83
  return gl[gi].value === ol[oi].value;
84
84
  }, (len, gi, oi) => {
85
85
  commonItems.push([gi, oi, len]);
package/lib/generate.js CHANGED
@@ -14,7 +14,7 @@ const { mergeV8Coverage, saveV8Report } = require('./v8/v8.js');
14
14
  const { convertV8List } = require('./converter/converter.js');
15
15
  const { resolveSourceMap } = require('./converter/collect-source-maps.js');
16
16
 
17
- const { minimatch } = require('./packages/monocart-coverage-vendor.js');
17
+ const { minimatch } = require('minimatch');
18
18
  const { getGroupedRows } = require('./utils/snapshot.js');
19
19
  const generateMarkdownGrid = require('./utils/markdown.js');
20
20