Skip to content

Commit

Permalink
fix(cli): fix misnamed package.json key
Browse files Browse the repository at this point in the history
  • Loading branch information
csprance authored and Romakita committed May 1, 2023
1 parent c49f4d8 commit c6dcb64
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 194 deletions.
4 changes: 2 additions & 2 deletions packages/cli-core/src/services/ProjectPackageJson.ts
Expand Up @@ -430,12 +430,12 @@ export class ProjectPackageJson {
...pkg.scripts
};

pkg.depencencies = {
pkg.dependencies = {
...this.raw.dependencies,
...pkg.dependencies
};

pkg.devDepencencies = {
pkg.devDependencies = {
...this.raw.devDependencies,
...pkg.devDependencies
};
Expand Down
192 changes: 0 additions & 192 deletions packages/cli/test/integrations/init/init.integration.spec.ts
Expand Up @@ -73,39 +73,6 @@ describe("Init cmd", () => {
const pkg = JSON.parse(FakeCliFs.entries.get("project-name/package.json")!);
expect(pkg).toMatchInlineSnapshot(`
Object {
"depencencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
"@tsed/core": "5.58.1",
"@tsed/di": "5.58.1",
"@tsed/engines": "latest",
"@tsed/exceptions": "5.58.1",
"@tsed/json-mapper": "5.58.1",
"@tsed/logger": "latest",
"@tsed/logger-file": "latest",
"@tsed/openspec": "5.58.1",
"@tsed/platform-cache": "5.58.1",
"@tsed/platform-exceptions": "5.58.1",
"@tsed/platform-express": "5.58.1",
"@tsed/platform-log-middleware": "5.58.1",
"@tsed/platform-middlewares": "5.58.1",
"@tsed/platform-params": "5.58.1",
"@tsed/platform-response-filter": "5.58.1",
"@tsed/platform-views": "5.58.1",
"@tsed/schema": "5.58.1",
"ajv": "latest",
"barrelsby": "latest",
"body-parser": "latest",
"compression": "latest",
"cookie-parser": "latest",
"cors": "latest",
"cross-env": "latest",
"dotenv": "latest",
"dotenv-expand": "latest",
"dotenv-flow": "latest",
"express": "latest",
"method-override": "latest",
},
"dependencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
Expand All @@ -125,20 +92,6 @@ describe("Init cmd", () => {
"@tsed/schema": "5.58.1",
},
"description": "",
"devDepencencies": Object {
"@types/compression": "latest",
"@types/cookie-parser": "latest",
"@types/cors": "latest",
"@types/express": "latest",
"@types/method-override": "latest",
"@types/multer": "latest",
"@types/node": "latest",
"ts-node": "latest",
"ts-node-dev": "latest",
"tsconfig-paths": "latest",
"tslib": "latest",
"typescript": "latest",
},
"devDependencies": Object {},
"name": "project-data",
"scripts": Object {
Expand Down Expand Up @@ -221,39 +174,6 @@ describe("Init cmd", () => {
const pkg = JSON.parse(FakeCliFs.entries.get("project-name/package.json")!);
expect(pkg).toMatchInlineSnapshot(`
Object {
"depencencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
"@tsed/core": "5.58.1",
"@tsed/di": "5.58.1",
"@tsed/engines": "latest",
"@tsed/exceptions": "5.58.1",
"@tsed/json-mapper": "5.58.1",
"@tsed/logger": "latest",
"@tsed/logger-file": "latest",
"@tsed/openspec": "5.58.1",
"@tsed/platform-cache": "5.58.1",
"@tsed/platform-exceptions": "5.58.1",
"@tsed/platform-express": "5.58.1",
"@tsed/platform-log-middleware": "5.58.1",
"@tsed/platform-middlewares": "5.58.1",
"@tsed/platform-params": "5.58.1",
"@tsed/platform-response-filter": "5.58.1",
"@tsed/platform-views": "5.58.1",
"@tsed/schema": "5.58.1",
"ajv": "latest",
"barrelsby": "latest",
"body-parser": "latest",
"compression": "latest",
"cookie-parser": "latest",
"cors": "latest",
"cross-env": "latest",
"dotenv": "latest",
"dotenv-expand": "latest",
"dotenv-flow": "latest",
"express": "latest",
"method-override": "latest",
},
"dependencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
Expand All @@ -273,20 +193,6 @@ describe("Init cmd", () => {
"@tsed/schema": "5.58.1",
},
"description": "",
"devDepencencies": Object {
"@types/compression": "latest",
"@types/cookie-parser": "latest",
"@types/cors": "latest",
"@types/express": "latest",
"@types/method-override": "latest",
"@types/multer": "latest",
"@types/node": "latest",
"ts-node": "latest",
"ts-node-dev": "latest",
"tsconfig-paths": "latest",
"tslib": "latest",
"typescript": "latest",
},
"devDependencies": Object {},
"name": "project-data",
"scripts": Object {
Expand Down Expand Up @@ -357,39 +263,6 @@ describe("Init cmd", () => {
const pkg = JSON.parse(FakeCliFs.entries.get("project-name/package.json")!);
expect(pkg).toMatchInlineSnapshot(`
Object {
"depencencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
"@tsed/core": "5.58.1",
"@tsed/di": "5.58.1",
"@tsed/engines": "latest",
"@tsed/exceptions": "5.58.1",
"@tsed/json-mapper": "5.58.1",
"@tsed/logger": "latest",
"@tsed/logger-file": "latest",
"@tsed/openspec": "5.58.1",
"@tsed/platform-cache": "5.58.1",
"@tsed/platform-exceptions": "5.58.1",
"@tsed/platform-express": "5.58.1",
"@tsed/platform-log-middleware": "5.58.1",
"@tsed/platform-middlewares": "5.58.1",
"@tsed/platform-params": "5.58.1",
"@tsed/platform-response-filter": "5.58.1",
"@tsed/platform-views": "5.58.1",
"@tsed/schema": "5.58.1",
"ajv": "latest",
"barrelsby": "latest",
"body-parser": "latest",
"compression": "latest",
"cookie-parser": "latest",
"cors": "latest",
"cross-env": "latest",
"dotenv": "latest",
"dotenv-expand": "latest",
"dotenv-flow": "latest",
"express": "latest",
"method-override": "latest",
},
"dependencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
Expand All @@ -409,20 +282,6 @@ describe("Init cmd", () => {
"@tsed/schema": "5.58.1",
},
"description": "",
"devDepencencies": Object {
"@types/compression": "latest",
"@types/cookie-parser": "latest",
"@types/cors": "latest",
"@types/express": "latest",
"@types/method-override": "latest",
"@types/multer": "latest",
"@types/node": "latest",
"ts-node": "latest",
"ts-node-dev": "latest",
"tsconfig-paths": "latest",
"tslib": "latest",
"typescript": "latest",
},
"devDependencies": Object {},
"name": "project-data",
"scripts": Object {
Expand Down Expand Up @@ -573,40 +432,6 @@ describe("Init cmd", () => {
const pkg = JSON.parse(FakeCliFs.entries.get("project-name/package.json")!);
expect(pkg).toMatchInlineSnapshot(`
Object {
"depencencies": Object {
"@koa/cors": "latest",
"@koa/router": "latest",
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
"@tsed/core": "5.58.1",
"@tsed/di": "5.58.1",
"@tsed/engines": "latest",
"@tsed/exceptions": "5.58.1",
"@tsed/json-mapper": "5.58.1",
"@tsed/logger": "latest",
"@tsed/logger-file": "latest",
"@tsed/openspec": "5.58.1",
"@tsed/platform-cache": "5.58.1",
"@tsed/platform-exceptions": "5.58.1",
"@tsed/platform-koa": "5.58.1",
"@tsed/platform-log-middleware": "5.58.1",
"@tsed/platform-middlewares": "5.58.1",
"@tsed/platform-params": "5.58.1",
"@tsed/platform-response-filter": "5.58.1",
"@tsed/platform-views": "5.58.1",
"@tsed/schema": "5.58.1",
"ajv": "latest",
"barrelsby": "latest",
"cross-env": "latest",
"dotenv": "latest",
"dotenv-expand": "latest",
"dotenv-flow": "latest",
"koa": "latest",
"koa-bodyparser": "latest",
"koa-compress": "latest",
"koa-override": "latest",
"koa-qs": "latest",
},
"dependencies": Object {
"@tsed/ajv": "5.58.1",
"@tsed/common": "5.58.1",
Expand All @@ -626,23 +451,6 @@ describe("Init cmd", () => {
"@tsed/schema": "5.58.1",
},
"description": "",
"devDepencencies": Object {
"@types/koa": "latest",
"@types/koa-bodyparser": "latest",
"@types/koa-compress": "latest",
"@types/koa-json": "latest",
"@types/koa-qs": "latest",
"@types/koa-send": "latest",
"@types/koa__cors": "latest",
"@types/koa__router": "latest",
"@types/multer": "latest",
"@types/node": "latest",
"ts-node": "latest",
"ts-node-dev": "latest",
"tsconfig-paths": "latest",
"tslib": "latest",
"typescript": "latest",
},
"devDependencies": Object {},
"name": "project-data",
"scripts": Object {
Expand Down

0 comments on commit c6dcb64

Please sign in to comment.