npq 2.5.0 → 2.5.2
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
|
@@ -100,6 +100,7 @@ Note: `npq` by default will offload all commands and their arguments to the `npm
|
|
|
100
100
|
| license | Will show a warning if a package has been found without a license field | Checks the latest version for a license
|
|
101
101
|
| expired domains | Will show a warning if a package has been found with one of its maintainers having an email address that includes an expired domain | Checks a dependency version for a maintainer with an expired domain
|
|
102
102
|
| signatures | Will compare the package's signature as it shows on the registry's pakument with the keys published on the npmjs.com registry
|
|
103
|
+
| provenance | Will verify the package's attestations of provenance metadata for the published package
|
|
103
104
|
|
|
104
105
|
### Disabling Marshalls
|
|
105
106
|
|
|
@@ -9,6 +9,10 @@ jest.mock('pacote', () => {
|
|
|
9
9
|
}
|
|
10
10
|
})
|
|
11
11
|
|
|
12
|
+
jest.mock('node-fetch')
|
|
13
|
+
|
|
14
|
+
const fetch = require('node-fetch')
|
|
15
|
+
|
|
12
16
|
const SignaturesMarshall = require('../lib/marshalls/signatures.marshall')
|
|
13
17
|
const pacote = require('pacote')
|
|
14
18
|
|
|
@@ -46,7 +50,7 @@ describe('Signature test suites', () => {
|
|
|
46
50
|
]
|
|
47
51
|
})
|
|
48
52
|
}
|
|
49
|
-
|
|
53
|
+
fetch.mockImplementationOnce(() => Promise.resolve(mockResponse))
|
|
50
54
|
|
|
51
55
|
const testMarshall = new SignaturesMarshall({
|
|
52
56
|
packageRepoUtils: {
|
|
@@ -103,7 +107,7 @@ describe('Signature test suites', () => {
|
|
|
103
107
|
]
|
|
104
108
|
})
|
|
105
109
|
}
|
|
106
|
-
|
|
110
|
+
fetch.mockImplementationOnce(() => Promise.resolve(mockResponse))
|
|
107
111
|
|
|
108
112
|
// the manifest() method should throw an error
|
|
109
113
|
// in this jest mock to simulate a problem:
|