@whook/create 9.0.0 → 9.0.1
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/dist/services/createWhook.test.js +3 -3
- package/dist/services/createWhook.test.js.map +1 -1
- package/dist/services/createWhook.test.mjs +3 -3
- package/dist/services/createWhook.test.mjs.map +1 -1
- package/package.json +6 -5
- package/src/services/__snapshots__/createWhook.test.ts.snap +4 -4
- package/src/services/createWhook.test.ts +3 -3
|
@@ -166,7 +166,7 @@ Mr Bean
|
|
|
166
166
|
"@whook/cli": "<current_version>",
|
|
167
167
|
"@whook/cors": "<current_version>",
|
|
168
168
|
"@whook/http-router": "<current_version>",
|
|
169
|
-
"@whook/http-server": "^
|
|
169
|
+
"@whook/http-server": "^9.0.0",
|
|
170
170
|
"@whook/http-transaction": "<current_version>",
|
|
171
171
|
"@whook/swagger-ui": "<current_version>",
|
|
172
172
|
"@whook/whook": "<current_version>",
|
|
@@ -400,7 +400,7 @@ Mr Bean
|
|
|
400
400
|
"@whook/cli": "<current_version>",
|
|
401
401
|
"@whook/cors": "<current_version>",
|
|
402
402
|
"@whook/http-router": "<current_version>",
|
|
403
|
-
"@whook/http-server": "^
|
|
403
|
+
"@whook/http-server": "^9.0.0",
|
|
404
404
|
"@whook/http-transaction": "<current_version>",
|
|
405
405
|
"@whook/swagger-ui": "<current_version>",
|
|
406
406
|
"@whook/whook": "<current_version>",
|
|
@@ -634,7 +634,7 @@ Mr Bean
|
|
|
634
634
|
"@whook/cli": "<current_version>",
|
|
635
635
|
"@whook/cors": "<current_version>",
|
|
636
636
|
"@whook/http-router": "<current_version>",
|
|
637
|
-
"@whook/http-server": "^
|
|
637
|
+
"@whook/http-server": "^9.0.0",
|
|
638
638
|
"@whook/http-transaction": "<current_version>",
|
|
639
639
|
"@whook/swagger-ui": "<current_version>",
|
|
640
640
|
"@whook/whook": "<current_version>",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createWhook.test.js","names":["_packageJSON","require","describe","CWD","SOURCE_DIR","packageJSON","dependencies","author","name","email","project","directory","writeFile","jest","fn","readFile","readdir","exec","copy","axios","ora","oraInstance","start","stopAndPersist","log","beforeEach","mockReset","mockReturnValue","mockResolvedValue","Buffer","from","it","mockResolvedValueOnce","JSON","stringify","mockImplementationOnce","_","_2","filter","Promise","all","map","fileName","data","undefined","cb","createWhook","initCreateWhook","expect","parse","mock","calls","find","call","endsWith","toMatchInlineSnapshot","copyCalls","writeFileCalls","readFileCalls","execCalls","oraCalls","oraStartCalls","oraStopAndPersistCalls","logCalls","type","readdirCalls","toMatchSnapshot","mockRejectedValueOnce","YError","err","errorCode","code","errorParams","params"],"sources":["../../src/services/createWhook.test.ts"],"sourcesContent":["import initCreateWhook from './createWhook';\nimport YError from 'yerror';\n\n// eslint-disable-next-line\nconst _packageJSON = require('@whook/example/package.json');\n\ndescribe('initCreateWhook', () => {\n const CWD = '/home/whoiam/projects/';\n const SOURCE_DIR = '/var/lib/node/node_modules/whook-example';\n const packageJSON = {\n ..._packageJSON,\n dependencies: {\n ..._packageJSON.dependencies,\n '@whook/authorization': '<current_version>',\n '@whook/cli': '<current_version>',\n '@whook/cors': '<current_version>',\n '@whook/http-router': '<current_version>',\n '@whook/http-transaction': '<current_version>',\n '@whook/swagger-ui': '<current_version>',\n '@whook/whook': '<current_version>',\n },\n };\n const author = {\n name: 'Wayne Campbell',\n email: 'wayne@warner.com',\n };\n const project = {\n name: 'super-project',\n directory: '/home/whoiam/projects/yolo',\n };\n const writeFile = jest.fn();\n const readFile = jest.fn();\n const readdir = jest.fn();\n const exec = jest.fn();\n const copy = jest.fn();\n const axios = jest.fn();\n const ora = jest.fn();\n const oraInstance = {\n start: jest.fn(),\n stopAndPersist: jest.fn(),\n };\n const log = jest.fn();\n\n beforeEach(() => {\n axios.mockReset();\n writeFile.mockReset();\n readFile.mockReset();\n readdir.mockReset();\n exec.mockReset();\n copy.mockReset();\n log.mockReset();\n ora.mockReset();\n ora.mockReturnValue(oraInstance);\n oraInstance.start.mockReset();\n oraInstance.start.mockReturnValue(oraInstance);\n oraInstance.stopAndPersist.mockReset();\n readFile.mockResolvedValue(\n Buffer.from(`\n# test\n> yolo\n\n[//]: # (::contents:start)\n\nYOLO\n\n[//]: # (::contents:end)\n\n# Authors\nMr Bean\n\n `),\n );\n });\n\n it('should work', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Initialized an empty git repository!'),\n );\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^8.5.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle network issues', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockRejectedValueOnce(new YError('E_NETWORK'));\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^8.5.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle git initialization problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockResolvedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^8.5.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should fail with access problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockRejectedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(null, ''));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n try {\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n throw new YError('E_UNEXPECTED_SUCCESS');\n } catch (err) {\n expect({\n errorCode: (err as YError).code,\n errorParams: (err as YError).params,\n }).toMatchInlineSnapshot(`\n Object {\n \"errorCode\": \"E_ACCESS\",\n \"errorParams\": Array [],\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readdir.mock.calls,\n }).toMatchSnapshot();\n }\n });\n});\n"],"mappings":";;AAAA;;AACA;;;;;;;;;;AAEA;AACA,MAAMA,YAAY,GAAGC,OAAO,CAAC,6BAAD,CAA5B;;AAEAC,QAAQ,CAAC,iBAAD,EAAoB,MAAM;EAChC,MAAMC,GAAG,GAAG,wBAAZ;EACA,MAAMC,UAAU,GAAG,0CAAnB;;EACA,MAAMC,WAAW,mCACZL,YADY;IAEfM,YAAY,kCACPN,YAAY,CAACM,YADN;MAEV,wBAAwB,mBAFd;MAGV,cAAc,mBAHJ;MAIV,eAAe,mBAJL;MAKV,sBAAsB,mBALZ;MAMV,2BAA2B,mBANjB;MAOV,qBAAqB,mBAPX;MAQV,gBAAgB;IARN;EAFG,EAAjB;;EAaA,MAAMC,MAAM,GAAG;IACbC,IAAI,EAAE,gBADO;IAEbC,KAAK,EAAE;EAFM,CAAf;EAIA,MAAMC,OAAO,GAAG;IACdF,IAAI,EAAE,eADQ;IAEdG,SAAS,EAAE;EAFG,CAAhB;EAIA,MAAMC,SAAS,GAAGC,IAAI,CAACC,EAAL,EAAlB;EACA,MAAMC,QAAQ,GAAGF,IAAI,CAACC,EAAL,EAAjB;EACA,MAAME,OAAO,GAAGH,IAAI,CAACC,EAAL,EAAhB;EACA,MAAMG,IAAI,GAAGJ,IAAI,CAACC,EAAL,EAAb;EACA,MAAMI,IAAI,GAAGL,IAAI,CAACC,EAAL,EAAb;EACA,MAAMK,KAAK,GAAGN,IAAI,CAACC,EAAL,EAAd;EACA,MAAMM,GAAG,GAAGP,IAAI,CAACC,EAAL,EAAZ;EACA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AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,MAAM,CAAC;MACLQ,SAAS,EAAEtC,IAAI,CAACgC,IAAL,CAAUC,KADhB;MAELM,cAAc,EAAE7C,SAAS,CAACsC,IAAV,CAAeC,KAF1B;MAGLO,aAAa,EAAE3C,QAAQ,CAACmC,IAAT,CAAcC,KAHxB;MAILQ,SAAS,EAAE1C,IAAI,CAACiC,IAAL,CAAUC,KAJhB;MAKLS,QAAQ,EAAExC,GAAG,CAAC8B,IAAJ,CAASC,KALd;MAMLU,aAAa,EAAExC,WAAW,CAACC,KAAZ,CAAkB4B,IAAlB,CAAuBC,KANjC;MAOLW,sBAAsB,EAAEzC,WAAW,CAACE,cAAZ,CAA2B2B,IAA3B,CAAgCC,KAPnD;MAQLY,QAAQ,EAAEvC,GAAG,CAAC0B,IAAJ,CAASC,KAAT,CAAeb,MAAf,CAAsB,CAAC,CA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ExCC,UAFwC;MAGxCG,MAHwC;MAIxCG,OAJwC;MAKxCE,SALwC;MAMxCG,QANwC;MAOxCC,OAPwC;MAQxCC,IAAI,EAAEA,IARkC;MASxCC,IATwC;MAUxCC,KAAK,EAAEA,KAViC;MAWxCC,GAAG,EAAEA,GAXmC;MAYxCI;IAZwC,CAAhB,CAA1B;IAeA,MAAMsB,WAAW,EAAjB;IAEAE,MAAM,CACJf,IAAI,CAACgB,KAAL,CACErC,SAAS,CAACsC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAC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ACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,MAAM,CAAC;MACLQ,SAAS,EAAEtC,IAAI,CAACgC,IAAL,CAAUC,KADhB;MAELM,cAAc,EAAE7C,SAAS,CAACsC,IAAV,CAAeC,KAF1B;MAGLO,aAAa,EAAE3C,QAAQ,CAACmC,IAAT,CAAcC,KAHxB;MAILQ,SAAS,EAAE1C,IAAI,CAACiC,IAAL,CAAUC,KAJhB;MAKLS,QAAQ,EAAExC,GAAG,CAAC8B,IAAJ,CAASC,KALd;MAMLU,aAAa,EAAExC,WAAW,CAACC,KAAZ,CAAkB4B,IAAlB,CAAuBC,KANjC;MAOLW,sBAAsB,EAAEzC,WAAW,CAACE,cAAZ,CAA2B2B,IAA3B,CAAgCC,KAPnD;MAQLY,QAAQ,EAAEvC,GAAG,CAAC0B,IAAJ,CAASC,KAAT,CAAeb,MAAf,CAAsB,CAAC,CAAC0B,IAAD,CAAD,KAAY,CAACA,IAAI,CAACV,QAAL,CAAc,OAAd,CAAnC,CARL;MASLW,YAAY,EAAElD,QAAQ,CAACmC,IAAT,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W,EAAGH,GAAD,CAAgBI;MAFxB,CAAD,CAAN,CAGGlB,qBAHH,CAG0B;AAChC;AACA;AACA;AACA;AACA,OARM;MASAP,MAAM,CAAC;QACLQ,SAAS,EAAEtC,IAAI,CAACgC,IAAL,CAAUC,KADhB;QAELM,cAAc,EAAE7C,SAAS,CAACsC,IAAV,CAAeC,KAF1B;QAGLO,aAAa,EAAE3C,QAAQ,CAACmC,IAAT,CAAcC,KAHxB;QAILQ,SAAS,EAAE1C,IAAI,CAACiC,IAAL,CAAUC,KAJhB;QAKLS,QAAQ,EAAExC,GAAG,CAAC8B,IAAJ,CAASC,KALd;QAMLU,aAAa,EAAExC,WAAW,CAACC,KAAZ,CAAkB4B,IAAlB,CAAuBC,KANjC;QAOLW,sBAAsB,EAAEzC,WAAW,CAACE,cAAZ,CAA2B2B,IAA3B,CAAgCC,KAPnD;QAQLY,QAAQ,EAAEvC,GAAG,CAAC0B,IAAJ,CAASC,KAAT,CAAeb,MAAf,CAAsB,CAAC,CAAC0B,IAAD,CAAD,KAAY,CAACA,IAAI,CAACV,QAAL,CAAc,OAAd,CAAnC,CARL;QASLW,YAAY,EAAEjD,OAAO,CAACkC,IAAR,CAAaC;MATtB,CAAD,CAAN,CAUGe,eAVH;IAWD;EACF,CAxDC,CAAF;AAyDD,CAj4BO,CAAR"}
|
|
1
|
+
{"version":3,"file":"createWhook.test.js","names":["_packageJSON","require","describe","CWD","SOURCE_DIR","packageJSON","dependencies","author","name","email","project","directory","writeFile","jest","fn","readFile","readdir","exec","copy","axios","ora","oraInstance","start","stopAndPersist","log","beforeEach","mockReset","mockReturnValue","mockResolvedValue","Buffer","from","it","mockResolvedValueOnce","JSON","stringify","mockImplementationOnce","_","_2","filter","Promise","all","map","fileName","data","undefined","cb","createWhook","initCreateWhook","expect","parse","mock","calls","find","call","endsWith","toMatchInlineSnapshot","copyCalls","writeFileCalls","readFileCalls","execCalls","oraCalls","oraStartCalls","oraStopAndPersistCalls","logCalls","type","readdirCalls","toMatchSnapshot","mockRejectedValueOnce","YError","err","errorCode","code","errorParams","params"],"sources":["../../src/services/createWhook.test.ts"],"sourcesContent":["import initCreateWhook from './createWhook';\nimport YError from 'yerror';\n\n// eslint-disable-next-line\nconst _packageJSON = require('@whook/example/package.json');\n\ndescribe('initCreateWhook', () => {\n const CWD = '/home/whoiam/projects/';\n const SOURCE_DIR = '/var/lib/node/node_modules/whook-example';\n const packageJSON = {\n ..._packageJSON,\n dependencies: {\n ..._packageJSON.dependencies,\n '@whook/authorization': '<current_version>',\n '@whook/cli': '<current_version>',\n '@whook/cors': '<current_version>',\n '@whook/http-router': '<current_version>',\n '@whook/http-transaction': '<current_version>',\n '@whook/swagger-ui': '<current_version>',\n '@whook/whook': '<current_version>',\n },\n };\n const author = {\n name: 'Wayne Campbell',\n email: 'wayne@warner.com',\n };\n const project = {\n name: 'super-project',\n directory: '/home/whoiam/projects/yolo',\n };\n const writeFile = jest.fn();\n const readFile = jest.fn();\n const readdir = jest.fn();\n const exec = jest.fn();\n const copy = jest.fn();\n const axios = jest.fn();\n const ora = jest.fn();\n const oraInstance = {\n start: jest.fn(),\n stopAndPersist: jest.fn(),\n };\n const log = jest.fn();\n\n beforeEach(() => {\n axios.mockReset();\n writeFile.mockReset();\n readFile.mockReset();\n readdir.mockReset();\n exec.mockReset();\n copy.mockReset();\n log.mockReset();\n ora.mockReset();\n ora.mockReturnValue(oraInstance);\n oraInstance.start.mockReset();\n oraInstance.start.mockReturnValue(oraInstance);\n oraInstance.stopAndPersist.mockReset();\n readFile.mockResolvedValue(\n Buffer.from(`\n# test\n> yolo\n\n[//]: # (::contents:start)\n\nYOLO\n\n[//]: # (::contents:end)\n\n# Authors\nMr Bean\n\n `),\n );\n });\n\n it('should work', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Initialized an empty git repository!'),\n );\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^9.0.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle network issues', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockRejectedValueOnce(new YError('E_NETWORK'));\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^9.0.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle git initialization problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockResolvedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^9.0.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should fail with access problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockRejectedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(null, ''));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n try {\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n throw new YError('E_UNEXPECTED_SUCCESS');\n } catch (err) {\n expect({\n errorCode: (err as YError).code,\n errorParams: (err as YError).params,\n }).toMatchInlineSnapshot(`\n Object {\n \"errorCode\": \"E_ACCESS\",\n \"errorParams\": Array [],\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readdir.mock.calls,\n }).toMatchSnapshot();\n }\n });\n});\n"],"mappings":";;AAAA;;AACA;;;;;;;;;;AAEA;AACA,MAAMA,YAAY,GAAGC,OAAO,CAAC,6BAAD,CAA5B;;A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C,CAAD,EAAIC,EAAJ,EAAQQ,EAAR,KAC1BA,EAAE,CAAC,IAAD,EAAO,yBAAP,CADJ;IAIA,MAAMC,WAAW,GAAG,MAAM,IAAAC,oBAAA,EAAgB;MACxC5C,GADwC;MAExCC,UAFwC;MAGxCG,MAHwC;MAIxCG,OAJwC;MAKxCE,SALwC;MAMxCG,QANwC;MAOxCC,OAPwC;MAQxCC,IAAI,EAAEA,IARkC;MASxCC,IATwC;MAUxCC,KAAK,EAAEA,KAViC;MAWxCC,GAAG,EAAEA,GAXmC;MAYxCI;IAZwC,CAAhB,CAA1B;IAeA,MAAMsB,WAAW,EAAjB;IAEAE,MAAM,CACJf,IAAI,CAACgB,KAAL,CACErC,SAAS,CAACsC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA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,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,MAAM,CAAC;MACLQ,SAAS,EAAEtC,IAAI,CAACgC,IAAL,CAAUC,KADhB;MAELM,cAAc,EAAE7C,SAAS,CAACsC,IAAV,CAAeC,KAF1B;MAGLO,aAAa,EAAE3C,QAAQ,CAACmC,IAAT,CAAcC,KAHxB;MAILQ,SAAS,EAAE1C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M,IAAAC,oBAAA,EAAgB;MACxC5C,GADwC;MAExCC,UAFwC;MAGxCG,MAHwC;MAIxCG,OAJwC;MAKxCE,SALwC;MAMxCG,QANwC;MAOxCC,OAPwC;MAQxCC,IAAI,EAAEA,IARkC;MASxCC,IATwC;MAUxCC,KAAK,EAAEA,KAViC;MAWxCC,GAAG,EAAEA,GAXmC;MAYxCI;IAZwC,CAAhB,CAA1B;IAeA,MAAMsB,WAAW,EAAjB;IAEAE,MAAM,CACJf,IAAI,CAACgB,KAAL,CACErC,SAAS,CAACsC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;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AASC,KALd;QAMLU,aAAa,EAAExC,WAAW,CAACC,KAAZ,CAAkB4B,IAAlB,CAAuBC,KANjC;QAOLW,sBAAsB,EAAEzC,WAAW,CAACE,cAAZ,CAA2B2B,IAA3B,CAAgCC,KAPnD;QAQLY,QAAQ,EAAEvC,GAAG,CAAC0B,IAAJ,CAASC,KAAT,CAAeb,MAAf,CAAsB,CAAC,CAAC0B,IAAD,CAAD,KAAY,CAACA,IAAI,CAACV,QAAL,CAAc,OAAd,CAAnC,CARL;QASLW,YAAY,EAAEjD,OAAO,CAACkC,IAAR,CAAaC;MATtB,CAAD,CAAN,CAUGe,eAVH;IAWD;EACF,CAxDC,CAAF;AAyDD,CAj4BO,CAAR"}
|
|
@@ -160,7 +160,7 @@ Mr Bean
|
|
|
160
160
|
"@whook/cli": "<current_version>",
|
|
161
161
|
"@whook/cors": "<current_version>",
|
|
162
162
|
"@whook/http-router": "<current_version>",
|
|
163
|
-
"@whook/http-server": "^
|
|
163
|
+
"@whook/http-server": "^9.0.0",
|
|
164
164
|
"@whook/http-transaction": "<current_version>",
|
|
165
165
|
"@whook/swagger-ui": "<current_version>",
|
|
166
166
|
"@whook/whook": "<current_version>",
|
|
@@ -394,7 +394,7 @@ Mr Bean
|
|
|
394
394
|
"@whook/cli": "<current_version>",
|
|
395
395
|
"@whook/cors": "<current_version>",
|
|
396
396
|
"@whook/http-router": "<current_version>",
|
|
397
|
-
"@whook/http-server": "^
|
|
397
|
+
"@whook/http-server": "^9.0.0",
|
|
398
398
|
"@whook/http-transaction": "<current_version>",
|
|
399
399
|
"@whook/swagger-ui": "<current_version>",
|
|
400
400
|
"@whook/whook": "<current_version>",
|
|
@@ -628,7 +628,7 @@ Mr Bean
|
|
|
628
628
|
"@whook/cli": "<current_version>",
|
|
629
629
|
"@whook/cors": "<current_version>",
|
|
630
630
|
"@whook/http-router": "<current_version>",
|
|
631
|
-
"@whook/http-server": "^
|
|
631
|
+
"@whook/http-server": "^9.0.0",
|
|
632
632
|
"@whook/http-transaction": "<current_version>",
|
|
633
633
|
"@whook/swagger-ui": "<current_version>",
|
|
634
634
|
"@whook/whook": "<current_version>",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createWhook.test.mjs","names":["initCreateWhook","YError","_packageJSON","require","describe","CWD","SOURCE_DIR","packageJSON","dependencies","author","name","email","project","directory","writeFile","jest","fn","readFile","readdir","exec","copy","axios","ora","oraInstance","start","stopAndPersist","log","beforeEach","mockReset","mockReturnValue","mockResolvedValue","Buffer","from","it","mockResolvedValueOnce","JSON","stringify","mockImplementationOnce","_","_2","filter","Promise","all","map","fileName","data","undefined","cb","createWhook","expect","parse","mock","calls","find","call","endsWith","toMatchInlineSnapshot","copyCalls","writeFileCalls","readFileCalls","execCalls","oraCalls","oraStartCalls","oraStopAndPersistCalls","logCalls","type","readdirCalls","toMatchSnapshot","mockRejectedValueOnce","err","errorCode","code","errorParams","params"],"sources":["../../src/services/createWhook.test.ts"],"sourcesContent":["import initCreateWhook from './createWhook';\nimport YError from 'yerror';\n\n// eslint-disable-next-line\nconst _packageJSON = require('@whook/example/package.json');\n\ndescribe('initCreateWhook', () => {\n const CWD = '/home/whoiam/projects/';\n const SOURCE_DIR = '/var/lib/node/node_modules/whook-example';\n const packageJSON = {\n ..._packageJSON,\n dependencies: {\n ..._packageJSON.dependencies,\n '@whook/authorization': '<current_version>',\n '@whook/cli': '<current_version>',\n '@whook/cors': '<current_version>',\n '@whook/http-router': '<current_version>',\n '@whook/http-transaction': '<current_version>',\n '@whook/swagger-ui': '<current_version>',\n '@whook/whook': '<current_version>',\n },\n };\n const author = {\n name: 'Wayne Campbell',\n email: 'wayne@warner.com',\n };\n const project = {\n name: 'super-project',\n directory: '/home/whoiam/projects/yolo',\n };\n const writeFile = jest.fn();\n const readFile = jest.fn();\n const readdir = jest.fn();\n const exec = jest.fn();\n const copy = jest.fn();\n const axios = jest.fn();\n const ora = jest.fn();\n const oraInstance = {\n start: jest.fn(),\n stopAndPersist: jest.fn(),\n };\n const log = jest.fn();\n\n beforeEach(() => {\n axios.mockReset();\n writeFile.mockReset();\n readFile.mockReset();\n readdir.mockReset();\n exec.mockReset();\n copy.mockReset();\n log.mockReset();\n ora.mockReset();\n ora.mockReturnValue(oraInstance);\n oraInstance.start.mockReset();\n oraInstance.start.mockReturnValue(oraInstance);\n oraInstance.stopAndPersist.mockReset();\n readFile.mockResolvedValue(\n Buffer.from(`\n# test\n> yolo\n\n[//]: # (::contents:start)\n\nYOLO\n\n[//]: # (::contents:end)\n\n# Authors\nMr Bean\n\n `),\n );\n });\n\n it('should work', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Initialized an empty git repository!'),\n );\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^8.5.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle network issues', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockRejectedValueOnce(new YError('E_NETWORK'));\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^8.5.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle git initialization problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockResolvedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^8.5.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should fail with access problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockRejectedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(null, ''));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n try {\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n throw new YError('E_UNEXPECTED_SUCCESS');\n } catch (err) {\n expect({\n errorCode: (err as YError).code,\n errorParams: (err as YError).params,\n }).toMatchInlineSnapshot(`\n Object {\n \"errorCode\": \"E_ACCESS\",\n \"errorParams\": Array [],\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readdir.mock.calls,\n }).toMatchSnapshot();\n }\n });\n});\n"],"mappings":";;;;;;AAAA,OAAOA,eAAP,MAA4B,eAA5B;AACA,OAAOC,MAAP,MAAmB,QAAnB,C,CAEA;;AACA,MAAMC,YAAY,GAAGC,OAAO,CAAC,6BAAD,CAA5B;;AAEAC,QAAQ,CAAC,iBAAD,EAAoB,MAAM;EAChC,MAAMC,GAAG,GAAG,wBAAZ;EACA,MAAMC,UAAU,GAAG,0CAAnB;;EACA,MAAMC,WAAW,mCACZL,YADY;IAEfM,YAAY,kCACPN,YAAY,CAACM,YADN;MAEV,wBAAwB,mBAFd;MAGV,cAAc,mBAHJ;MAIV,eAAe,mBAJL;MAKV,sBAAsB,mBALZ;MAMV,2BAA2B,mBANjB;MAOV,qBAAqB,mBAPX;MAQV,gBAAgB;IARN;EAFG,EAAjB;;EAaA,MAAMC,MAAM,GAAG;IACbC,IAAI,EAAE,gBADO;IAEbC,KAAK,EAAE;EAFM,CAAf;EAIA,MAAMC,OAAO,GAAG;IACdF,IAAI,EAAE,eADQ;IAEdG,SAAS,EAAE;EAFG,CAAhB;EAIA,MAAMC,SAAS,GAAGC,IAAI,CAACC,EAAL,EAAlB;EACA,MAAMC,QAAQ,GAAGF,IAAI,CAACC,EAAL,EAAjB;EACA,MAAME,OAAO,GAAGH,IAAI,CAACC,EAAL,EAAhB;EACA,MAA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A;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,MAAM,CAAC;MACLQ,SAAS,EAAErC,IAAI,CAAC+B,IAAL,CAAUC,KADhB;MAELM,cAAc,EAAE5C,SAAS,CAACqC,IAAV,CAAeC,KAF1B;MAGLO,aAAa,EAAE1C,QAAQ,CAACkC,IAAT,CAAcC,KAHxB;MAILQ,SAAS,EAAEzC,IAAI,CAACgC,IAAL,CAAUC,KAJhB;MAKLS,QAAQ,EAAEvC,GAAG,CAAC6B,IAAJ,CAASC,KALd;MAMLU,aAAa,EAAEvC,WAAW,CAACC,KAAZ,CAAk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B,IAAI,CAACkB,sBAAL,CAA4B,CAACC,CAAD,EAAIC,EAAJ,EAAQQ,EAAR,KAC1BA,EAAE,CAAC,IAAD,EAAO,yBAAP,CADJ;IAIA,MAAMC,WAAW,GAAG,MAAMhD,eAAe,CAAC;MACxCK,GADwC;MAExCC,UAFwC;MAGxCG,MAHwC;MAIxCG,OAJwC;MAKxCE,SALwC;MAMxCG,QANwC;MAOxCC,OAPwC;MAQxCC,IAAI,EAAEA,IARkC;MASxCC,IATwC;MAUxCC,KAAK,EAAEA,KAViC;MAWxCC,GAAG,EAAEA,GAXmC;MAYxCI;IAZwC,CAAD,CAAzC;IAeA,MAAMsB,WAAW,EAAjB;IAEAC,MAAM,CACJd,IAAI,CAACe,KAAL,CACEpC,SAAS,CAACqC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA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ACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,MAAM,CAAC;MACLQ,SAAS,EAAErC,IAAI,CAAC+B,IAAL,CAAUC,KADhB;MAELM,cAAc,EAAE5C,SAAS,CAACqC,IAAV,CAAeC,KAF1B;MAGLO,aAAa,EAAE1C,QAAQ,CAACkC,IAAT,CAAcC,KAHxB;MAILQ,SAAS,EAAEzC,IAAI,CAACgC,IAAL,CAAUC,KAJhB;MAKLS,QAAQ,EAAEvC,GAAG,CAAC6B,IAAJ,CAASC,KALd;MAMLU,aAAa,EAAEvC,WAAW,CAACC,KAAZ,CAAkB2B,IAAlB,CAAuBC,KANjC;MAOLW,sBAAsB,EAAExC,WAAW,CAACE,cAAZ,CAA2B0B,IAA3B,CAAgCC,KAPnD;MAQLY,QAAQ,EAAEtC,GAAG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AjB;MAEA,MAAM,IAAI/C,MAAJ,CAAW,sBAAX,CAAN;IACD,CAnBD,CAmBE,OAAOoE,GAAP,EAAY;MACZpB,MAAM,CAAC;QACLqB,SAAS,EAAGD,GAAD,CAAgBE,IADtB;QAELC,WAAW,EAAGH,GAAD,CAAgBI;MAFxB,CAAD,CAAN,CAGGjB,qBAHH,CAG0B;AAChC;AACA;AACA;AACA;AACA,OARM;MASAP,MAAM,CAAC;QACLQ,SAAS,EAAErC,IAAI,CAAC+B,IAAL,CAAUC,KADhB;QAELM,cAAc,EAAE5C,SAAS,CAACqC,IAAV,CAAeC,KAF1B;QAGLO,aAAa,EAAE1C,QAAQ,CAACkC,IAAT,CAAcC,KAHxB;QAILQ,SAAS,EAAEzC,IAAI,CAACgC,IAAL,CAAUC,KAJhB;QAKLS,QAAQ,EAAEvC,GAAG,CAAC6B,IAAJ,CAASC,KALd;QAMLU,aAAa,EAAEvC,WAAW,CAACC,KAAZ,CAAkB2B,IAAlB,CAAuBC,KANjC;QAOLW,sBAAsB,EAAExC,WAAW,CAACE,cAAZ,CAA2B0B,IAA3B,CAAgCC,KAPnD;QAQLY,QAAQ,EAAEtC,GAAG,CAACyB,IAAJ,CAASC,KAAT,CAAeZ,MAAf,CAAsB,CAAC,CAACyB,IAAD,CAAD,KAAY,CAACA,IAAI,CAACV,QAAL,CAAc,OAAd,CAAnC,CARL;QASLW,YAAY,EAAEhD,OAAO,CAACiC,IAAR,CAAaC;MATtB,CAAD,CAAN,CAUGe,eAVH;IAWD;EACF,CAxDC,CAAF;AAyDD,CAj4BO,CAAR"}
|
|
1
|
+
{"version":3,"file":"createWhook.test.mjs","names":["initCreateWhook","YError","_packageJSON","require","describe","CWD","SOURCE_DIR","packageJSON","dependencies","author","name","email","project","directory","writeFile","jest","fn","readFile","readdir","exec","copy","axios","ora","oraInstance","start","stopAndPersist","log","beforeEach","mockReset","mockReturnValue","mockResolvedValue","Buffer","from","it","mockResolvedValueOnce","JSON","stringify","mockImplementationOnce","_","_2","filter","Promise","all","map","fileName","data","undefined","cb","createWhook","expect","parse","mock","calls","find","call","endsWith","toMatchInlineSnapshot","copyCalls","writeFileCalls","readFileCalls","execCalls","oraCalls","oraStartCalls","oraStopAndPersistCalls","logCalls","type","readdirCalls","toMatchSnapshot","mockRejectedValueOnce","err","errorCode","code","errorParams","params"],"sources":["../../src/services/createWhook.test.ts"],"sourcesContent":["import initCreateWhook from './createWhook';\nimport YError from 'yerror';\n\n// eslint-disable-next-line\nconst _packageJSON = require('@whook/example/package.json');\n\ndescribe('initCreateWhook', () => {\n const CWD = '/home/whoiam/projects/';\n const SOURCE_DIR = '/var/lib/node/node_modules/whook-example';\n const packageJSON = {\n ..._packageJSON,\n dependencies: {\n ..._packageJSON.dependencies,\n '@whook/authorization': '<current_version>',\n '@whook/cli': '<current_version>',\n '@whook/cors': '<current_version>',\n '@whook/http-router': '<current_version>',\n '@whook/http-transaction': '<current_version>',\n '@whook/swagger-ui': '<current_version>',\n '@whook/whook': '<current_version>',\n },\n };\n const author = {\n name: 'Wayne Campbell',\n email: 'wayne@warner.com',\n };\n const project = {\n name: 'super-project',\n directory: '/home/whoiam/projects/yolo',\n };\n const writeFile = jest.fn();\n const readFile = jest.fn();\n const readdir = jest.fn();\n const exec = jest.fn();\n const copy = jest.fn();\n const axios = jest.fn();\n const ora = jest.fn();\n const oraInstance = {\n start: jest.fn(),\n stopAndPersist: jest.fn(),\n };\n const log = jest.fn();\n\n beforeEach(() => {\n axios.mockReset();\n writeFile.mockReset();\n readFile.mockReset();\n readdir.mockReset();\n exec.mockReset();\n copy.mockReset();\n log.mockReset();\n ora.mockReset();\n ora.mockReturnValue(oraInstance);\n oraInstance.start.mockReset();\n oraInstance.start.mockReturnValue(oraInstance);\n oraInstance.stopAndPersist.mockReset();\n readFile.mockResolvedValue(\n Buffer.from(`\n# test\n> yolo\n\n[//]: # (::contents:start)\n\nYOLO\n\n[//]: # (::contents:end)\n\n# Authors\nMr Bean\n\n `),\n );\n });\n\n it('should work', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Initialized an empty git repository!'),\n );\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^9.0.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle network issues', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockImplementationOnce((_, _2, { filter }) =>\n Promise.all(\n [\n 'package.json',\n 'package-lock.json',\n 'LICENSE',\n 'dist/index.js',\n 'src/index.js',\n 'coverage/index.html',\n 'node_modules/whook/index.js',\n ].map((fileName) =>\n filter(\n `${SOURCE_DIR}/${fileName}`,\n `${project.directory}/${fileName}`,\n ),\n ),\n ),\n );\n axios.mockRejectedValueOnce(new YError('E_NETWORK'));\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^9.0.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should handle git initialization problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockResolvedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(new YError('E_ACCESS')));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n expect(\n JSON.parse(\n writeFile.mock.calls.find((call) =>\n call[0].endsWith('package.json'),\n )[1],\n ),\n ).toMatchInlineSnapshot(`\n Object {\n \"author\": Object {\n \"email\": \"wayne@warner.com\",\n \"name\": \"Wayne Campbell\",\n },\n \"babel\": Object {\n \"env\": Object {\n \"cjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": \"commonjs\",\n \"targets\": Object {\n \"node\": \"10\",\n },\n },\n ],\n ],\n },\n \"mjs\": Object {\n \"presets\": Array [\n Array [\n \"@babel/env\",\n Object {\n \"modules\": false,\n \"targets\": Object {\n \"node\": \"12\",\n },\n },\n ],\n ],\n },\n },\n \"plugins\": Array [\n \"@babel/proposal-class-properties\",\n \"@babel/plugin-proposal-object-rest-spread\",\n \"babel-plugin-knifecycle\",\n ],\n \"presets\": Array [\n \"@babel/typescript\",\n Array [\n \"@babel/env\",\n Object {\n \"targets\": Object {\n \"node\": \"12.19.0\",\n },\n },\n ],\n ],\n \"sourceMaps\": true,\n },\n \"dependencies\": Object {\n \"@whook/authorization\": \"<current_version>\",\n \"@whook/cli\": \"<current_version>\",\n \"@whook/cors\": \"<current_version>\",\n \"@whook/http-router\": \"<current_version>\",\n \"@whook/http-server\": \"^9.0.0\",\n \"@whook/http-transaction\": \"<current_version>\",\n \"@whook/swagger-ui\": \"<current_version>\",\n \"@whook/whook\": \"<current_version>\",\n \"common-services\": \"^10.0.2\",\n \"http-auth-utils\": \"^3.0.3\",\n \"jwt-service\": \"^8.0.1\",\n \"knifecycle\": \"^12.0.4\",\n \"openapi-schema-validator\": \"^11.0.1\",\n \"openapi-types\": \"^11.0.1\",\n \"strict-qs\": \"^6.1.5\",\n \"type-fest\": \"^2.13.0\",\n \"yerror\": \"^6.0.2\",\n \"yhttperror\": \"^6.0.3\",\n },\n \"description\": \"A new Whook project\",\n \"devDependencies\": Object {\n \"@babel/cli\": \"^7.17.10\",\n \"@babel/core\": \"^7.18.2\",\n \"@babel/eslint-parser\": \"^7.18.2\",\n \"@babel/node\": \"^7.13.13\",\n \"@babel/plugin-proposal-class-properties\": \"^7.17.12\",\n \"@babel/plugin-proposal-object-rest-spread\": \"^7.18.0\",\n \"@babel/plugin-syntax-dynamic-import\": \"^7.8.3\",\n \"@babel/plugin-syntax-import-meta\": \"^7.10.4\",\n \"@babel/preset-env\": \"^7.18.2\",\n \"@babel/preset-typescript\": \"^7.17.12\",\n \"@babel/register\": \"^7.17.7\",\n \"@types/jest\": \"^27.0.2\",\n \"@typescript-eslint/eslint-plugin\": \"^5.26.0\",\n \"@typescript-eslint/parser\": \"^5.26.0\",\n \"axios\": \"^0.27.2\",\n \"babel-plugin-knifecycle\": \"^5.0.3\",\n \"chokidar\": \"^3.5.1\",\n \"eslint\": \"^8.16.0\",\n \"eslint-plugin-prettier\": \"^4.0.0\",\n \"jest\": \"^28.1.0\",\n \"jsarch\": \"^5.0.1\",\n \"parse-gitignore\": \"^1.0.1\",\n \"prettier\": \"^2.6.2\",\n \"rimraf\": \"^3.0.2\",\n \"schema2dts\": \"^4.1.1\",\n \"typescript\": \"^4.7.2\",\n },\n \"engines\": Object {\n \"node\": \">=12.19.0\",\n },\n \"eslintConfig\": Object {\n \"env\": Object {\n \"es6\": true,\n \"jest\": true,\n \"mocha\": true,\n \"node\": true,\n },\n \"extends\": Array [\n \"eslint:recommended\",\n \"plugin:@typescript-eslint/eslint-recommended\",\n \"plugin:@typescript-eslint/recommended\",\n ],\n \"ignorePatterns\": Array [\n \"*.d.ts\",\n ],\n \"parser\": \"@typescript-eslint/parser\",\n \"parserOptions\": Object {\n \"ecmaVersion\": 2018,\n \"modules\": true,\n \"sourceType\": \"module\",\n },\n \"plugins\": Array [\n \"prettier\",\n ],\n \"rules\": Object {\n \"prettier/prettier\": \"error\",\n },\n },\n \"files\": Array [\n \"bin\",\n \"dist\",\n \"src\",\n \"LICENSE\",\n \"README.md\",\n \"CHANGELOG.md\",\n ],\n \"jest\": Object {\n \"coverageReporters\": Array [\n \"lcov\",\n \"html\",\n ],\n \"roots\": Array [\n \"<rootDir>/src\",\n ],\n \"testEnvironment\": \"node\",\n \"testPathIgnorePatterns\": Array [\n \"/node_modules/\",\n ],\n },\n \"keywords\": Array [\n \"whook\",\n ],\n \"license\": \"SEE LICENSE\",\n \"main\": \"dist/index\",\n \"module\": \"dist/index.mjs\",\n \"name\": \"super-project\",\n \"prettier\": Object {\n \"printWidth\": 80,\n \"proseWrap\": \"always\",\n \"semi\": true,\n \"singleQuote\": true,\n \"trailingComma\": \"all\",\n },\n \"private\": true,\n \"scripts\": Object {\n \"apitypes\": \"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\",\n \"architecture\": \"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\",\n \"build\": \"npm run compile && NODE_ENV=\\${NODE_ENV:-development} node bin/build\",\n \"compile\": \"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\",\n \"compile:cjs\": \"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"compile:mjs\": \"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\",\n \"cover\": \"npm run jest -- --coverage\",\n \"debug\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\",\n \"dev\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\",\n \"genPackagelock\": \"npm i --package-lock-only\",\n \"jest\": \"NODE_ENV=test jest\",\n \"lint\": \"eslint 'src/**/*.ts'\",\n \"prettier\": \"prettier --write 'src/**/*.ts'\",\n \"start\": \"NODE_ENV=\\${NODE_ENV:-development} node bin/start\",\n \"test\": \"npm run jest\",\n \"types\": \"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\",\n \"watch\": \"NODE_ENV=\\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\",\n \"whook\": \"NODE_ENV=\\${NODE_ENV:-development} whook\",\n \"whook-dev\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\",\n \"whook-repl\": \"PROJECT_SRC=\\\\\"$PWD/src\\\\\" NODE_ENV=\\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\",\n },\n \"types\": \"dist/index.d.ts\",\n \"version\": \"0.0.0\",\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]) => !type.endsWith('stack')),\n readdirCalls: readFile.mock.calls,\n }).toMatchSnapshot();\n });\n\n it('should fail with access problems', async () => {\n readFile.mockResolvedValueOnce(JSON.stringify(packageJSON));\n readdir.mockResolvedValueOnce(['development', 'production']);\n copy.mockRejectedValueOnce(new YError('E_ACCESS'));\n axios.mockResolvedValueOnce({\n data: 'node_modules',\n });\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n writeFile.mockResolvedValueOnce(undefined);\n exec.mockImplementationOnce((_, _2, cb) => cb(null, ''));\n exec.mockImplementationOnce((_, _2, cb) =>\n cb(null, 'Installed dependencies!'),\n );\n\n try {\n const createWhook = await initCreateWhook({\n CWD,\n SOURCE_DIR,\n author,\n project,\n writeFile,\n readFile,\n readdir,\n exec: exec as any,\n copy,\n axios: axios as any,\n ora: ora as any,\n log,\n });\n\n await createWhook();\n\n throw new YError('E_UNEXPECTED_SUCCESS');\n } catch (err) {\n expect({\n errorCode: (err as YError).code,\n errorParams: (err as YError).params,\n }).toMatchInlineSnapshot(`\n Object {\n \"errorCode\": \"E_ACCESS\",\n \"errorParams\": Array [],\n }\n `);\n expect({\n copyCalls: copy.mock.calls,\n writeFileCalls: writeFile.mock.calls,\n readFileCalls: readFile.mock.calls,\n execCalls: exec.mock.calls,\n oraCalls: ora.mock.calls,\n oraStartCalls: oraInstance.start.mock.calls,\n oraStopAndPersistCalls: oraInstance.stopAndPersist.mock.calls,\n logCalls: log.mock.calls.filter(([type]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CY,SAAhC;IACAhC,SAAS,CAACoB,qBAAV,CAAgCY,SAAhC;IACA3B,IAAI,CAACkB,sBAAL,CAA4B,CAACC,CAAD,EAAIC,EAAJ,EAAQQ,EAAR,KAC1BA,EAAE,CAAC,IAAD,EAAO,sCAAP,CADJ;IAGA5B,IAAI,CAACkB,sBAAL,CAA4B,CAACC,CAAD,EAAIC,EAAJ,EAAQQ,EAAR,KAC1BA,EAAE,CAAC,IAAD,EAAO,yBAAP,CADJ;IAIA,MAAMC,WAAW,GAAG,MAAMhD,eAAe,CAAC;MACxCK,GADwC;MAExCC,UAFwC;MAGxCG,MAHwC;MAIxCG,OAJwC;MAKxCE,SALwC;MAMxCG,QANwC;MAOxCC,OAPwC;MAQxCC,IAAI,EAAEA,IARkC;MASxCC,IATwC;MAUxCC,KAAK,EAAEA,KAViC;MAWxCC,GAAG,EAAEA,GAXmC;MAYxCI;IAZwC,CAAD,CAAzC;IAeA,MAAMsB,WAAW,EAAjB;IAEAC,MAAM,CACJd,IAAI,CAACe,KAAL,CACEpC,SAAS,CAACqC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,MAAM,CAAC;MACLQ,SAAS,EAAErC,IAAI,CAAC+B,IAAL,CAAUC,KADhB;MAELM,cAAc,EAAE5C,SAAS,CAACqC,IAAV,CAAeC,KAF1B;MAGLO,aAAa,EAAE1C,QAAQ,CAACkC,IAAT,CAAcC,KAHxB;MAILQ,SAAS,EAAEzC,IAAI,CAACgC,IAAL,CAAUC,KAJhB;MAKLS,QAAQ,EAAEvC,GAAG,CAAC6B,IAAJ,CAASC,KALd;MAMLU,aAAa,EAAEvC,WAAW,CAACC,KAAZ,CAAkB2B,IAAlB,CAAuBC,KANjC;MAOLW,sBAAsB,EAAExC,WAAW,CAACE,cAAZ,CAA2B0B,IAA3B,CAAgCC,KAPnD;MAQLY,QAAQ,EAAEtC,GAAG,CAACyB,IAAJ,CAASC,KAAT,CAAeZ,MAAf,CAAsB,CAAC,CAACyB,IAAD,CAAD,KAAY,CAACA,IAAI,CAACV,QAAL,CAAc,OAAd,CAAnC,CARL;MASLW,YAAY,EAAEjD,QAAQ,CAACkC,IAAT,CAAcC;IATvB,CAAD,CAAN,CAUGe,eAVH;EAWD,CAvQC,CAAF;EA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XmC;MAYxCI;IAZwC,CAAD,CAAzC;IAeA,MAAMsB,WAAW,EAAjB;IAEAC,MAAM,CACJd,IAAI,CAACe,KAAL,CACEpC,SAAS,CAACqC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAxMI;IAyMAP,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,CAAC,IAAI9C,MAAJ,CAAW,UAAX,CAAD,CAA7C;IACAkB,IAAI,CAACkB,sBAAL,CAA4B,CAACC,CAAD,EAAIC,EAAJ,EAAQQ,EAAR,KAC1BA,EAAE,CAAC,IAAD,EAAO,yBAAP,CADJ;IAIA,MAAMC,WAAW,GAAG,MAAMhD,eAAe,CAAC;MACxCK,GADwC;MAExCC,UAFwC;MAGxCG,MAHwC;MAIxCG,OAJwC;MAKxCE,SALwC;MAMxCG,QANwC;MAOxCC,OAPwC;MAQxCC,IAAI,EAAEA,IARkC;MASxCC,IATwC;MAUxCC,KAAK,EAAEA,KAViC;MAWxCC,GAAG,EAAEA,GAXmC;MAYxCI;IAZwC,CAAD,CAAzC;IAeA,MAAMsB,WAAW,EAAjB;IAEAC,MAAM,CACJd,IAAI,CAACe,KAAL,CACEpC,SAAS,CAACqC,IAAV,CAAeC,KAAf,CAAqBC,IAArB,CAA2BC,IAAD,IACxBA,IAAI,CAAC,CAAD,CAAJ,CAAQC,QAAR,CAAiB,cAAjB,CADF,EAEE,CAFF,CADF,CADI,CAAN,CAMEC,qBANF,CAMyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA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ACqC,IAAV,CAAeC,KAF1B;QAGLO,aAAa,EAAE1C,QAAQ,CAACkC,IAAT,CAAcC,KAHxB;QAILQ,SAAS,EAAEzC,IAAI,CAACgC,IAAL,CAAUC,KAJhB;QAKLS,QAAQ,EAAEvC,GAAG,CAAC6B,IAAJ,CAASC,KALd;QAMLU,aAAa,EAAEvC,WAAW,CAACC,KAAZ,CAAkB2B,IAAlB,CAAuBC,KANjC;QAOLW,sBAAsB,EAAExC,WAAW,CAACE,cAAZ,CAA2B0B,IAA3B,CAAgCC,KAPnD;QAQLY,QAAQ,EAAEtC,GAAG,CAACyB,IAAJ,CAASC,KAAT,CAAeZ,MAAf,CAAsB,CAAC,CAACyB,IAAD,CAAD,KAAY,CAACA,IAAI,CAACV,QAAL,CAAc,OAAd,CAAnC,CARL;QASLW,YAAY,EAAEhD,OAAO,CAACiC,IAAR,CAAaC;MATtB,CAAD,CAAN,CAUGe,eAVH;IAWD;EACF,CAxDC,CAAF;AAyDD,CAj4BO,CAAR"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@whook/create",
|
|
3
|
-
"version": "9.0.
|
|
3
|
+
"version": "9.0.1",
|
|
4
4
|
"description": "Kickstart a new Whook server",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"whook",
|
|
@@ -74,8 +74,8 @@
|
|
|
74
74
|
},
|
|
75
75
|
"homepage": "https://github.com/nfroidure/whook",
|
|
76
76
|
"dependencies": {
|
|
77
|
-
"@whook/cli": "^9.0.
|
|
78
|
-
"@whook/example": "^9.0.
|
|
77
|
+
"@whook/cli": "^9.0.1",
|
|
78
|
+
"@whook/example": "^9.0.1",
|
|
79
79
|
"axios": "^0.27.2",
|
|
80
80
|
"common-services": "^10.0.2",
|
|
81
81
|
"debug": "^4.3.4",
|
|
@@ -104,7 +104,7 @@
|
|
|
104
104
|
"eslint": "^8.16.0",
|
|
105
105
|
"eslint-plugin-prettier": "^4.0.0",
|
|
106
106
|
"jest": "^28.1.0",
|
|
107
|
-
"metapak": "^4.0.
|
|
107
|
+
"metapak": "^4.0.4",
|
|
108
108
|
"metapak-nfroidure": "11.2.1",
|
|
109
109
|
"prettier": "^2.6.2",
|
|
110
110
|
"rimraf": "^3.0.2",
|
|
@@ -214,5 +214,6 @@
|
|
|
214
214
|
"roots": [
|
|
215
215
|
"<rootDir>/src"
|
|
216
216
|
]
|
|
217
|
-
}
|
|
217
|
+
},
|
|
218
|
+
"gitHead": "a5620b3eacf3b500a5db59db9997bf7ed60668d5"
|
|
218
219
|
}
|
|
@@ -66,7 +66,7 @@ Wayne Campbell
|
|
|
66
66
|
],
|
|
67
67
|
Array [
|
|
68
68
|
"/home/whoiam/projects/yolo/package.json",
|
|
69
|
-
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^
|
|
69
|
+
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^9.0.0\\",\\"@whook/http-transaction\\":\\"<current_version>\\",\\"@whook/swagger-ui\\":\\"<current_version>\\",\\"@whook/whook\\":\\"<current_version>\\",\\"common-services\\":\\"^10.0.2\\",\\"http-auth-utils\\":\\"^3.0.3\\",\\"jwt-service\\":\\"^8.0.1\\",\\"knifecycle\\":\\"^12.0.4\\",\\"openapi-schema-validator\\":\\"^11.0.1\\",\\"openapi-types\\":\\"^11.0.1\\",\\"strict-qs\\":\\"^6.1.5\\",\\"type-fest\\":\\"^2.13.0\\",\\"yerror\\":\\"^6.0.2\\",\\"yhttperror\\":\\"^6.0.3\\"},\\"devDependencies\\":{\\"@babel/cli\\":\\"^7.17.10\\",\\"@babel/core\\":\\"^7.18.2\\",\\"@babel/eslint-parser\\":\\"^7.18.2\\",\\"@babel/node\\":\\"^7.13.13\\",\\"@babel/plugin-proposal-class-properties\\":\\"^7.17.12\\",\\"@babel/plugin-proposal-object-rest-spread\\":\\"^7.18.0\\",\\"@babel/plugin-syntax-dynamic-import\\":\\"^7.8.3\\",\\"@babel/plugin-syntax-import-meta\\":\\"^7.10.4\\",\\"@babel/preset-env\\":\\"^7.18.2\\",\\"@babel/preset-typescript\\":\\"^7.17.12\\",\\"@babel/register\\":\\"^7.17.7\\",\\"@types/jest\\":\\"^27.0.2\\",\\"@typescript-eslint/eslint-plugin\\":\\"^5.26.0\\",\\"@typescript-eslint/parser\\":\\"^5.26.0\\",\\"axios\\":\\"^0.27.2\\",\\"babel-plugin-knifecycle\\":\\"^5.0.3\\",\\"chokidar\\":\\"^3.5.1\\",\\"eslint\\":\\"^8.16.0\\",\\"eslint-plugin-prettier\\":\\"^4.0.0\\",\\"jest\\":\\"^28.1.0\\",\\"jsarch\\":\\"^5.0.1\\",\\"parse-gitignore\\":\\"^1.0.1\\",\\"prettier\\":\\"^2.6.2\\",\\"rimraf\\":\\"^3.0.2\\",\\"schema2dts\\":\\"^4.1.1\\",\\"typescript\\":\\"^4.7.2\\"},\\"eslintConfig\\":{\\"extends\\":[\\"eslint:recommended\\",\\"plugin:@typescript-eslint/eslint-recommended\\",\\"plugin:@typescript-eslint/recommended\\"],\\"parserOptions\\":{\\"ecmaVersion\\":2018,\\"sourceType\\":\\"module\\",\\"modules\\":true},\\"env\\":{\\"es6\\":true,\\"node\\":true,\\"jest\\":true,\\"mocha\\":true},\\"plugins\\":[\\"prettier\\"],\\"rules\\":{\\"prettier/prettier\\":\\"error\\"},\\"parser\\":\\"@typescript-eslint/parser\\",\\"ignorePatterns\\":[\\"*.d.ts\\"]},\\"prettier\\":{\\"semi\\":true,\\"printWidth\\":80,\\"singleQuote\\":true,\\"trailingComma\\":\\"all\\",\\"proseWrap\\":\\"always\\"},\\"babel\\":{\\"presets\\":[\\"@babel/typescript\\",[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12.19.0\\"}}]],\\"plugins\\":[\\"@babel/proposal-class-properties\\",\\"@babel/plugin-proposal-object-rest-spread\\",\\"babel-plugin-knifecycle\\"],\\"env\\":{\\"cjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"10\\"},\\"modules\\":\\"commonjs\\"}]]},\\"mjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12\\"},\\"modules\\":false}]]}},\\"sourceMaps\\":true},\\"jest\\":{\\"coverageReporters\\":[\\"lcov\\",\\"html\\"],\\"testPathIgnorePatterns\\":[\\"/node_modules/\\"],\\"roots\\":[\\"<rootDir>/src\\"],\\"testEnvironment\\":\\"node\\"}}",
|
|
70
70
|
],
|
|
71
71
|
Array [
|
|
72
72
|
"/home/whoiam/projects/yolo/LICENSE",
|
|
@@ -191,7 +191,7 @@ Wayne Campbell
|
|
|
191
191
|
],
|
|
192
192
|
Array [
|
|
193
193
|
"/home/whoiam/projects/yolo/package.json",
|
|
194
|
-
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^
|
|
194
|
+
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^9.0.0\\",\\"@whook/http-transaction\\":\\"<current_version>\\",\\"@whook/swagger-ui\\":\\"<current_version>\\",\\"@whook/whook\\":\\"<current_version>\\",\\"common-services\\":\\"^10.0.2\\",\\"http-auth-utils\\":\\"^3.0.3\\",\\"jwt-service\\":\\"^8.0.1\\",\\"knifecycle\\":\\"^12.0.4\\",\\"openapi-schema-validator\\":\\"^11.0.1\\",\\"openapi-types\\":\\"^11.0.1\\",\\"strict-qs\\":\\"^6.1.5\\",\\"type-fest\\":\\"^2.13.0\\",\\"yerror\\":\\"^6.0.2\\",\\"yhttperror\\":\\"^6.0.3\\"},\\"devDependencies\\":{\\"@babel/cli\\":\\"^7.17.10\\",\\"@babel/core\\":\\"^7.18.2\\",\\"@babel/eslint-parser\\":\\"^7.18.2\\",\\"@babel/node\\":\\"^7.13.13\\",\\"@babel/plugin-proposal-class-properties\\":\\"^7.17.12\\",\\"@babel/plugin-proposal-object-rest-spread\\":\\"^7.18.0\\",\\"@babel/plugin-syntax-dynamic-import\\":\\"^7.8.3\\",\\"@babel/plugin-syntax-import-meta\\":\\"^7.10.4\\",\\"@babel/preset-env\\":\\"^7.18.2\\",\\"@babel/preset-typescript\\":\\"^7.17.12\\",\\"@babel/register\\":\\"^7.17.7\\",\\"@types/jest\\":\\"^27.0.2\\",\\"@typescript-eslint/eslint-plugin\\":\\"^5.26.0\\",\\"@typescript-eslint/parser\\":\\"^5.26.0\\",\\"axios\\":\\"^0.27.2\\",\\"babel-plugin-knifecycle\\":\\"^5.0.3\\",\\"chokidar\\":\\"^3.5.1\\",\\"eslint\\":\\"^8.16.0\\",\\"eslint-plugin-prettier\\":\\"^4.0.0\\",\\"jest\\":\\"^28.1.0\\",\\"jsarch\\":\\"^5.0.1\\",\\"parse-gitignore\\":\\"^1.0.1\\",\\"prettier\\":\\"^2.6.2\\",\\"rimraf\\":\\"^3.0.2\\",\\"schema2dts\\":\\"^4.1.1\\",\\"typescript\\":\\"^4.7.2\\"},\\"eslintConfig\\":{\\"extends\\":[\\"eslint:recommended\\",\\"plugin:@typescript-eslint/eslint-recommended\\",\\"plugin:@typescript-eslint/recommended\\"],\\"parserOptions\\":{\\"ecmaVersion\\":2018,\\"sourceType\\":\\"module\\",\\"modules\\":true},\\"env\\":{\\"es6\\":true,\\"node\\":true,\\"jest\\":true,\\"mocha\\":true},\\"plugins\\":[\\"prettier\\"],\\"rules\\":{\\"prettier/prettier\\":\\"error\\"},\\"parser\\":\\"@typescript-eslint/parser\\",\\"ignorePatterns\\":[\\"*.d.ts\\"]},\\"prettier\\":{\\"semi\\":true,\\"printWidth\\":80,\\"singleQuote\\":true,\\"trailingComma\\":\\"all\\",\\"proseWrap\\":\\"always\\"},\\"babel\\":{\\"presets\\":[\\"@babel/typescript\\",[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12.19.0\\"}}]],\\"plugins\\":[\\"@babel/proposal-class-properties\\",\\"@babel/plugin-proposal-object-rest-spread\\",\\"babel-plugin-knifecycle\\"],\\"env\\":{\\"cjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"10\\"},\\"modules\\":\\"commonjs\\"}]]},\\"mjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12\\"},\\"modules\\":false}]]}},\\"sourceMaps\\":true},\\"jest\\":{\\"coverageReporters\\":[\\"lcov\\",\\"html\\"],\\"testPathIgnorePatterns\\":[\\"/node_modules/\\"],\\"roots\\":[\\"<rootDir>/src\\"],\\"testEnvironment\\":\\"node\\"}}",
|
|
195
195
|
],
|
|
196
196
|
Array [
|
|
197
197
|
"/home/whoiam/projects/yolo/LICENSE",
|
|
@@ -348,7 +348,7 @@ Wayne Campbell
|
|
|
348
348
|
],
|
|
349
349
|
Array [
|
|
350
350
|
"/home/whoiam/projects/yolo/package.json",
|
|
351
|
-
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^
|
|
351
|
+
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^9.0.0\\",\\"@whook/http-transaction\\":\\"<current_version>\\",\\"@whook/swagger-ui\\":\\"<current_version>\\",\\"@whook/whook\\":\\"<current_version>\\",\\"common-services\\":\\"^10.0.2\\",\\"http-auth-utils\\":\\"^3.0.3\\",\\"jwt-service\\":\\"^8.0.1\\",\\"knifecycle\\":\\"^12.0.4\\",\\"openapi-schema-validator\\":\\"^11.0.1\\",\\"openapi-types\\":\\"^11.0.1\\",\\"strict-qs\\":\\"^6.1.5\\",\\"type-fest\\":\\"^2.13.0\\",\\"yerror\\":\\"^6.0.2\\",\\"yhttperror\\":\\"^6.0.3\\"},\\"devDependencies\\":{\\"@babel/cli\\":\\"^7.17.10\\",\\"@babel/core\\":\\"^7.18.2\\",\\"@babel/eslint-parser\\":\\"^7.18.2\\",\\"@babel/node\\":\\"^7.13.13\\",\\"@babel/plugin-proposal-class-properties\\":\\"^7.17.12\\",\\"@babel/plugin-proposal-object-rest-spread\\":\\"^7.18.0\\",\\"@babel/plugin-syntax-dynamic-import\\":\\"^7.8.3\\",\\"@babel/plugin-syntax-import-meta\\":\\"^7.10.4\\",\\"@babel/preset-env\\":\\"^7.18.2\\",\\"@babel/preset-typescript\\":\\"^7.17.12\\",\\"@babel/register\\":\\"^7.17.7\\",\\"@types/jest\\":\\"^27.0.2\\",\\"@typescript-eslint/eslint-plugin\\":\\"^5.26.0\\",\\"@typescript-eslint/parser\\":\\"^5.26.0\\",\\"axios\\":\\"^0.27.2\\",\\"babel-plugin-knifecycle\\":\\"^5.0.3\\",\\"chokidar\\":\\"^3.5.1\\",\\"eslint\\":\\"^8.16.0\\",\\"eslint-plugin-prettier\\":\\"^4.0.0\\",\\"jest\\":\\"^28.1.0\\",\\"jsarch\\":\\"^5.0.1\\",\\"parse-gitignore\\":\\"^1.0.1\\",\\"prettier\\":\\"^2.6.2\\",\\"rimraf\\":\\"^3.0.2\\",\\"schema2dts\\":\\"^4.1.1\\",\\"typescript\\":\\"^4.7.2\\"},\\"eslintConfig\\":{\\"extends\\":[\\"eslint:recommended\\",\\"plugin:@typescript-eslint/eslint-recommended\\",\\"plugin:@typescript-eslint/recommended\\"],\\"parserOptions\\":{\\"ecmaVersion\\":2018,\\"sourceType\\":\\"module\\",\\"modules\\":true},\\"env\\":{\\"es6\\":true,\\"node\\":true,\\"jest\\":true,\\"mocha\\":true},\\"plugins\\":[\\"prettier\\"],\\"rules\\":{\\"prettier/prettier\\":\\"error\\"},\\"parser\\":\\"@typescript-eslint/parser\\",\\"ignorePatterns\\":[\\"*.d.ts\\"]},\\"prettier\\":{\\"semi\\":true,\\"printWidth\\":80,\\"singleQuote\\":true,\\"trailingComma\\":\\"all\\",\\"proseWrap\\":\\"always\\"},\\"babel\\":{\\"presets\\":[\\"@babel/typescript\\",[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12.19.0\\"}}]],\\"plugins\\":[\\"@babel/proposal-class-properties\\",\\"@babel/plugin-proposal-object-rest-spread\\",\\"babel-plugin-knifecycle\\"],\\"env\\":{\\"cjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"10\\"},\\"modules\\":\\"commonjs\\"}]]},\\"mjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12\\"},\\"modules\\":false}]]}},\\"sourceMaps\\":true},\\"jest\\":{\\"coverageReporters\\":[\\"lcov\\",\\"html\\"],\\"testPathIgnorePatterns\\":[\\"/node_modules/\\"],\\"roots\\":[\\"<rootDir>/src\\"],\\"testEnvironment\\":\\"node\\"}}",
|
|
352
352
|
],
|
|
353
353
|
Array [
|
|
354
354
|
"/home/whoiam/projects/yolo/LICENSE",
|
|
@@ -493,7 +493,7 @@ Wayne Campbell
|
|
|
493
493
|
],
|
|
494
494
|
Array [
|
|
495
495
|
"/home/whoiam/projects/yolo/package.json",
|
|
496
|
-
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^
|
|
496
|
+
"{\\"name\\":\\"super-project\\",\\"description\\":\\"A new Whook project\\",\\"version\\":\\"0.0.0\\",\\"license\\":\\"SEE LICENSE\\",\\"engines\\":{\\"node\\":\\">=12.19.0\\"},\\"main\\":\\"dist/index\\",\\"module\\":\\"dist/index.mjs\\",\\"types\\":\\"dist/index.d.ts\\",\\"private\\":true,\\"keywords\\":[\\"whook\\"],\\"author\\":{\\"name\\":\\"Wayne Campbell\\",\\"email\\":\\"wayne@warner.com\\"},\\"scripts\\":{\\"apitypes\\":\\"npm run --silent whook -- generateOpenAPISchema --authenticated=true | npm run --silent whook -- generateOpenAPITypes > src/openAPISchema.d.ts\\",\\"architecture\\":\\"jsarch 'src/**/*.ts' > ARCHITECTURE.md && git add ARCHITECTURE.md\\",\\"build\\":\\"npm run compile && NODE_ENV=\${NODE_ENV:-development} node bin/build\\",\\"compile\\":\\"rimraf -f 'dist' && npm run compile:cjs && npm run compile:mjs\\",\\"compile:cjs\\":\\"babel --env-name=cjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"compile:mjs\\":\\"babel --env-name=mjs --out-file-extension=.mjs --out-dir=dist --extensions '.ts,.js' --source-maps=true src\\",\\"cover\\":\\"npm run jest -- --coverage\\",\\"debug\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 DEBUG=\${DEBUG:-whook} babel-node --extensions '.ts,.js' --inspect bin/dev\\",\\"dev\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/dev\\",\\"genPackagelock\\":\\"npm i --package-lock-only\\",\\"jest\\":\\"NODE_ENV=test jest\\",\\"lint\\":\\"eslint 'src/**/*.ts'\\",\\"prettier\\":\\"prettier --write 'src/**/*.ts'\\",\\"start\\":\\"NODE_ENV=\${NODE_ENV:-development} node bin/start\\",\\"test\\":\\"npm run jest\\",\\"types\\":\\"rimraf -f 'dist/**/*.d.ts' && tsc --project . --declaration --emitDeclarationOnly --outDir dist\\",\\"watch\\":\\"NODE_ENV=\${NODE_ENV:-development} DEV_MODE=1 DESTROY_SOCKETS=1 babel-node --extensions '.ts,.js' bin/watch\\",\\"whook\\":\\"NODE_ENV=\${NODE_ENV:-development} whook\\",\\"whook-dev\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- node_modules/@whook/cli/bin/whook.js\\",\\"whook-repl\\":\\"PROJECT_SRC=\\\\\\"$PWD/src\\\\\\" NODE_ENV=\${NODE_ENV:-development} babel-node --extensions '.ts,.js' -- bin/repl.js\\"},\\"files\\":[\\"bin\\",\\"dist\\",\\"src\\",\\"LICENSE\\",\\"README.md\\",\\"CHANGELOG.md\\"],\\"dependencies\\":{\\"@whook/authorization\\":\\"<current_version>\\",\\"@whook/cli\\":\\"<current_version>\\",\\"@whook/cors\\":\\"<current_version>\\",\\"@whook/http-router\\":\\"<current_version>\\",\\"@whook/http-server\\":\\"^9.0.0\\",\\"@whook/http-transaction\\":\\"<current_version>\\",\\"@whook/swagger-ui\\":\\"<current_version>\\",\\"@whook/whook\\":\\"<current_version>\\",\\"common-services\\":\\"^10.0.2\\",\\"http-auth-utils\\":\\"^3.0.3\\",\\"jwt-service\\":\\"^8.0.1\\",\\"knifecycle\\":\\"^12.0.4\\",\\"openapi-schema-validator\\":\\"^11.0.1\\",\\"openapi-types\\":\\"^11.0.1\\",\\"strict-qs\\":\\"^6.1.5\\",\\"type-fest\\":\\"^2.13.0\\",\\"yerror\\":\\"^6.0.2\\",\\"yhttperror\\":\\"^6.0.3\\"},\\"devDependencies\\":{\\"@babel/cli\\":\\"^7.17.10\\",\\"@babel/core\\":\\"^7.18.2\\",\\"@babel/eslint-parser\\":\\"^7.18.2\\",\\"@babel/node\\":\\"^7.13.13\\",\\"@babel/plugin-proposal-class-properties\\":\\"^7.17.12\\",\\"@babel/plugin-proposal-object-rest-spread\\":\\"^7.18.0\\",\\"@babel/plugin-syntax-dynamic-import\\":\\"^7.8.3\\",\\"@babel/plugin-syntax-import-meta\\":\\"^7.10.4\\",\\"@babel/preset-env\\":\\"^7.18.2\\",\\"@babel/preset-typescript\\":\\"^7.17.12\\",\\"@babel/register\\":\\"^7.17.7\\",\\"@types/jest\\":\\"^27.0.2\\",\\"@typescript-eslint/eslint-plugin\\":\\"^5.26.0\\",\\"@typescript-eslint/parser\\":\\"^5.26.0\\",\\"axios\\":\\"^0.27.2\\",\\"babel-plugin-knifecycle\\":\\"^5.0.3\\",\\"chokidar\\":\\"^3.5.1\\",\\"eslint\\":\\"^8.16.0\\",\\"eslint-plugin-prettier\\":\\"^4.0.0\\",\\"jest\\":\\"^28.1.0\\",\\"jsarch\\":\\"^5.0.1\\",\\"parse-gitignore\\":\\"^1.0.1\\",\\"prettier\\":\\"^2.6.2\\",\\"rimraf\\":\\"^3.0.2\\",\\"schema2dts\\":\\"^4.1.1\\",\\"typescript\\":\\"^4.7.2\\"},\\"eslintConfig\\":{\\"extends\\":[\\"eslint:recommended\\",\\"plugin:@typescript-eslint/eslint-recommended\\",\\"plugin:@typescript-eslint/recommended\\"],\\"parserOptions\\":{\\"ecmaVersion\\":2018,\\"sourceType\\":\\"module\\",\\"modules\\":true},\\"env\\":{\\"es6\\":true,\\"node\\":true,\\"jest\\":true,\\"mocha\\":true},\\"plugins\\":[\\"prettier\\"],\\"rules\\":{\\"prettier/prettier\\":\\"error\\"},\\"parser\\":\\"@typescript-eslint/parser\\",\\"ignorePatterns\\":[\\"*.d.ts\\"]},\\"prettier\\":{\\"semi\\":true,\\"printWidth\\":80,\\"singleQuote\\":true,\\"trailingComma\\":\\"all\\",\\"proseWrap\\":\\"always\\"},\\"babel\\":{\\"presets\\":[\\"@babel/typescript\\",[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12.19.0\\"}}]],\\"plugins\\":[\\"@babel/proposal-class-properties\\",\\"@babel/plugin-proposal-object-rest-spread\\",\\"babel-plugin-knifecycle\\"],\\"env\\":{\\"cjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"10\\"},\\"modules\\":\\"commonjs\\"}]]},\\"mjs\\":{\\"presets\\":[[\\"@babel/env\\",{\\"targets\\":{\\"node\\":\\"12\\"},\\"modules\\":false}]]}},\\"sourceMaps\\":true},\\"jest\\":{\\"coverageReporters\\":[\\"lcov\\",\\"html\\"],\\"testPathIgnorePatterns\\":[\\"/node_modules/\\"],\\"roots\\":[\\"<rootDir>/src\\"],\\"testEnvironment\\":\\"node\\"}}",
|
|
497
497
|
],
|
|
498
498
|
Array [
|
|
499
499
|
"/home/whoiam/projects/yolo/LICENSE",
|
|
@@ -187,7 +187,7 @@ Mr Bean
|
|
|
187
187
|
"@whook/cli": "<current_version>",
|
|
188
188
|
"@whook/cors": "<current_version>",
|
|
189
189
|
"@whook/http-router": "<current_version>",
|
|
190
|
-
"@whook/http-server": "^
|
|
190
|
+
"@whook/http-server": "^9.0.0",
|
|
191
191
|
"@whook/http-transaction": "<current_version>",
|
|
192
192
|
"@whook/swagger-ui": "<current_version>",
|
|
193
193
|
"@whook/whook": "<current_version>",
|
|
@@ -448,7 +448,7 @@ Mr Bean
|
|
|
448
448
|
"@whook/cli": "<current_version>",
|
|
449
449
|
"@whook/cors": "<current_version>",
|
|
450
450
|
"@whook/http-router": "<current_version>",
|
|
451
|
-
"@whook/http-server": "^
|
|
451
|
+
"@whook/http-server": "^9.0.0",
|
|
452
452
|
"@whook/http-transaction": "<current_version>",
|
|
453
453
|
"@whook/swagger-ui": "<current_version>",
|
|
454
454
|
"@whook/whook": "<current_version>",
|
|
@@ -694,7 +694,7 @@ Mr Bean
|
|
|
694
694
|
"@whook/cli": "<current_version>",
|
|
695
695
|
"@whook/cors": "<current_version>",
|
|
696
696
|
"@whook/http-router": "<current_version>",
|
|
697
|
-
"@whook/http-server": "^
|
|
697
|
+
"@whook/http-server": "^9.0.0",
|
|
698
698
|
"@whook/http-transaction": "<current_version>",
|
|
699
699
|
"@whook/swagger-ui": "<current_version>",
|
|
700
700
|
"@whook/whook": "<current_version>",
|