mirror of
https://github.com/oven-sh/bun
synced 2026-02-17 22:32:06 +00:00
56 lines
1.6 KiB
Plaintext
56 lines
1.6 KiB
Plaintext
// Bun Snapshot v1, https://bun.sh/docs/test/snapshots
|
|
|
|
exports[`should report error on invalid format for package.json 1`] = `
|
|
"1 | foo
|
|
^
|
|
error: Unexpected foo
|
|
at [dir]/package.json:1:1
|
|
ParserError parsing package.json in "[dir]/"
|
|
"
|
|
`;
|
|
|
|
exports[`should report error on invalid format for dependencies 1`] = `
|
|
"1 | {"name":"foo","version":"0.0.1","dependencies":[]}
|
|
^
|
|
error: dependencies expects a map of specifiers, e.g.
|
|
"dependencies": {
|
|
<green>"bun"<r>: <green>"latest"<r>
|
|
}
|
|
at [dir]/package.json:1:33
|
|
"
|
|
`;
|
|
|
|
exports[`should report error on invalid format for workspaces 1`] = `
|
|
"1 | {"name":"foo","version":"0.0.1","workspaces":{"packages":{"bar":true}}}
|
|
^
|
|
error: "workspaces.packages" expects an array of strings, e.g.
|
|
"workspaces": {
|
|
"packages": [
|
|
"path/to/package"
|
|
]
|
|
}
|
|
at [dir]/package.json:1:58
|
|
"
|
|
`;
|
|
|
|
exports[`should handle modified git resolutions in bun.lock 1`] = `"{"lockfileVersion":0,"workspaces":{"":{"dependencies":{"jquery":"3.7.1"}}},"packages":{"jquery":["jquery@git+ssh://git@github.com/dylan-conway/install-test-8.git#3a1288830817d13da39e9231302261896f8721ea",{},"3a1288830817d13da39e9231302261896f8721ea"]}}"`;
|
|
|
|
exports[`should read install.saveTextLockfile from bunfig.toml 1`] = `
|
|
"{
|
|
"lockfileVersion": 1,
|
|
"workspaces": {
|
|
"": {
|
|
"name": "foo",
|
|
},
|
|
"packages/pkg1": {
|
|
"name": "pkg-one",
|
|
"version": "1.0.0",
|
|
},
|
|
},
|
|
"packages": {
|
|
"pkg-one": ["pkg-one@workspace:packages/pkg1"],
|
|
}
|
|
}
|
|
"
|
|
`;
|