1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-28 10:09:20 -05:00
denoland-deno/tests/specs/add/dev/__test__.jsonc
Nathan Whitaker 98e8e2f8bc
feat(add/install): Flag to add dev dependency to package.json (#25495)
```
deno install --dev npm:chalk
```
Adds to `devDependencies` if a `package.json` is present, otherwise it
just adds to `imports` in `deno.json`
2024-09-07 02:22:27 -07:00

39 lines
825 B
Text

{
"tempDir": true,
"tests": {
"package_json": {
"steps": [
{
"args": "add --dev npm:@denotest/esm-basic",
"output": "add.out"
},
{
"args": [
"eval",
"console.log(Deno.readTextFileSync('package.json').trim())"
],
"output": "package.json.out"
}
]
},
"deno_json": {
"steps": [
{
"args": ["eval", "Deno.removeSync('package.json')"],
"output": ""
},
{
"args": "add --dev npm:@denotest/esm-basic",
"output": "add.out"
},
{
"args": [
"eval",
"console.log(Deno.readTextFileSync('deno.json').trim())"
],
"output": "deno.json.out"
}
]
}
}
}