feat: bump lockfile version to 5.2

This commit is contained in:
Zoltan Kochan
2020-05-16 20:22:51 +03:00
parent 242cf8737b
commit ca9f50844f
3 changed files with 8 additions and 2 deletions

View File

@@ -0,0 +1,5 @@
---
"@pnpm/constants": major
---
Bump lockfile version to 5.2.

View File

@@ -1,5 +1,5 @@
export const WANTED_LOCKFILE = 'pnpm-lock.yaml'
export const LOCKFILE_VERSION = 5.1
export const LOCKFILE_VERSION = 5.2
export const ENGINE_NAME = `${process.platform}-${process.arch}-node-${process.version.split('.')[0]}`
export const LAYOUT_VERSION = 4

View File

@@ -1,3 +1,4 @@
import { LOCKFILE_VERSION } from '@pnpm/constants'
import { Lockfile } from '@pnpm/lockfile-file'
import { prepareEmpty } from '@pnpm/prepare'
import sinon = require('sinon')
@@ -46,7 +47,7 @@ test('readPackage, afterAllResolved hooks', async (t: tape.Test) => {
await project.storeHas('dep-of-pkg-with-1-dep', '100.0.0')
t.ok(afterAllResolved.calledOnce, 'afterAllResolved() called once')
t.equal(afterAllResolved.getCall(0).args[0].lockfileVersion, 5.1)
t.equal(afterAllResolved.getCall(0).args[0].lockfileVersion, LOCKFILE_VERSION)
const wantedLockfile = await project.readLockfile()
t.equal(wantedLockfile['foo'], 'foo', 'the lockfile object has been updated by the hook') // tslint:disable-line:no-string-literal