Skip to content

Commit

Permalink
chore(deps): bump p-map from 4.0.0 to 6.0.0 (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
dependabot[bot] authored Dec 3, 2023
1 parent 334f0a1 commit 6808e6f
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 18 deletions.
4 changes: 3 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ const path = require('path')
const { rimraf } = require('rimraf')
const SourceMaps = require('./lib/source-maps')
const TestExclude = require('test-exclude')
const pMap = require('p-map')
const getPackageType = require('get-package-type')

const debugLog = debuglog('nyc')
Expand Down Expand Up @@ -233,6 +232,7 @@ class NYC {
this._loadAdditionalModules()

const stats = await fs.lstat(input)
const { default: pMap } = await import('p-map')
if (stats.isDirectory()) {
inputDir = input

Expand Down Expand Up @@ -421,6 +421,7 @@ class NYC {
async getCoverageMapFromAllCoverageFiles (baseDirectory) {
const map = libCoverage.createCoverageMap({})
const files = await this.coverageFiles(baseDirectory)
const { default: pMap } = await import('p-map')

await pMap(
files,
Expand Down Expand Up @@ -523,6 +524,7 @@ class NYC {
// TODO: Remove from nyc v16
async coverageData (baseDirectory) {
const files = await this.coverageFiles(baseDirectory)
const { default: pMap } = await import('p-map')
return pMap(
files,
f => this.coverageFileLoad(f, baseDirectory),
Expand Down
2 changes: 1 addition & 1 deletion lib/source-maps.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ const libSourceMaps = require('istanbul-lib-source-maps')
const fs = require('./fs-promises')
const os = require('os')
const path = require('path')
const pMap = require('p-map')

class SourceMaps {
constructor (opts) {
Expand Down Expand Up @@ -57,6 +56,7 @@ class SourceMaps {
}

async reloadCachedSourceMaps (report) {
const { default: pMap } = await import('p-map')
await pMap(
Object.entries(report),
async ([absFile, fileReport]) => {
Expand Down
24 changes: 9 additions & 15 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
"istanbul-reports": "^3.0.2",
"make-dir": "^3.0.0",
"node-preload": "^0.2.1",
"p-map": "^4.0.0",
"p-map": "^6.0.0",
"process-on-spawn": "^1.0.0",
"resolve-from": "^5.0.0",
"rimraf": "^5.0.1",
Expand Down

0 comments on commit 6808e6f

Please sign in to comment.