diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 2fb4dac..c38be3d 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -15,7 +15,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-node@v1 with: - node-version: '20.x' + node-version: '21.x' registry-url: 'https://registry.npmjs.org' - name: Install dependencies diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f7b3713..e5054bc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ jobs: strategy: matrix: node-version: - - 20.x + - 21.x steps: - uses: actions/checkout@v2 with: @@ -28,7 +28,7 @@ jobs: run: npm install - name: Run tests - run: npm run test + run: npm run test:coverage - name: Test code compilation run: npm run build @@ -38,7 +38,7 @@ jobs: strategy: matrix: node-version: - - 20.x + - 21.x steps: - uses: actions/checkout@v2 - name: Use Node.js ${{ matrix.node-version }} @@ -50,7 +50,7 @@ jobs: run: npm install - name: Run tests - run: npm run test + run: npm run test:coverage - name: Test code compilation run: npm run build diff --git a/package-lock.json b/package-lock.json index 5de1345..8714e66 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,27 +1,27 @@ { "name": "@athenna/core", - "version": "4.13.0", + "version": "4.14.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@athenna/core", - "version": "4.13.0", + "version": "4.14.0", "license": "MIT", "dependencies": { "pretty-repl": "^3.1.2", "semver": "^7.5.4" }, "devDependencies": { - "@athenna/artisan": "^4.15.0", - "@athenna/common": "^4.18.0", - "@athenna/config": "^4.7.0", - "@athenna/http": "^4.11.0", - "@athenna/ioc": "^4.7.0", - "@athenna/logger": "^4.8.0", - "@athenna/test": "^4.12.0", - "@athenna/tsconfig": "^4.9.2", - "@athenna/view": "^4.6.0", + "@athenna/artisan": "^4.16.0", + "@athenna/common": "^4.21.0", + "@athenna/config": "^4.8.0", + "@athenna/http": "^4.12.0", + "@athenna/ioc": "^4.8.0", + "@athenna/logger": "^4.9.0", + "@athenna/test": "^4.13.0", + "@athenna/tsconfig": "^4.11.0", + "@athenna/view": "^4.7.0", "@typescript-eslint/eslint-plugin": "^6.7.4", "@typescript-eslint/parser": "^6.7.4", "commitizen": "^4.2.6", @@ -97,9 +97,9 @@ "dev": true }, "node_modules/@athenna/artisan": { - "version": "4.15.0", - "resolved": "https://registry.npmjs.org/@athenna/artisan/-/artisan-4.15.0.tgz", - "integrity": "sha512-w3cgelmuO1GeQE3cswsOFDPPSvTVYpXE6H3VOlIaCetELPDnwp7b3PUG70WdvXUQD/j690LjiFFbY2qgM1pAlQ==", + "version": "4.17.0", + "resolved": "https://registry.npmjs.org/@athenna/artisan/-/artisan-4.17.0.tgz", + "integrity": "sha512-V8dYDi2Gv5OqrmXjrdKHWN2Is1AafLU8UzC8YSaekjXulmzxUwg/NY8Fn5+/VBR0E8VEnw9F5c/RyUyTlAEJDA==", "dev": true, "dependencies": { "chalk-rainbow": "^1.0.0", @@ -107,8 +107,8 @@ "cli-table3": "^0.6.3", "columnify": "^1.6.0", "commander": "^9.5.0", - "figlet": "^1.6.0", - "inquirer": "^9.2.11", + "figlet": "^1.7.0", + "inquirer": "^9.2.12", "log-update": "^5.0.1", "ora": "^6.3.1" }, @@ -117,9 +117,9 @@ } }, "node_modules/@athenna/common": { - "version": "4.18.0", - "resolved": "https://registry.npmjs.org/@athenna/common/-/common-4.18.0.tgz", - "integrity": "sha512-vYUEcQu80V5zjFf0WjKJ7f9XmhmtziFUL1l6VfH+h6ZHnNWvcjlIYoHU1pONTnVC9b8vFElrJHWz7xo5IDFvIA==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/@athenna/common/-/common-4.21.0.tgz", + "integrity": "sha512-1FCgoWxFzKHyC72UMa49VRaQMxbZS6PpagBE4pxAN0YqQ3hYQM8XDToVHc9NP/4geVyb2p5Qz3N06M/GpJn3jA==", "dev": true, "dependencies": { "@fastify/formbody": "^7.4.0", @@ -129,10 +129,11 @@ "change-case": "^4.1.2", "collect.js": "^4.36.1", "execa": "^8.0.1", - "fastify": "^4.23.2", + "fastify": "^4.24.0", "got": "^12.6.1", "http-status-codes": "^2.2.0", "is-wsl": "^2.2.0", + "js-yaml": "^4.1.0", "kind-of": "^6.0.3", "lodash": "^4.17.21", "mime-types": "^2.1.35", @@ -143,21 +144,39 @@ "prepend-file": "^2.0.1", "uuid": "^8.3.2", "validator-brazil": "^1.2.2", - "youch": "^3.3.1", + "youch": "^3.3.3", "youch-terminal": "^2.2.2" }, "engines": { - "node": ">=20.0.0" + "node": ">=21.0.0" + } + }, + "node_modules/@athenna/common/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true + }, + "node_modules/@athenna/common/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dev": true, + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" } }, "node_modules/@athenna/config": { - "version": "4.7.0", - "resolved": "https://registry.npmjs.org/@athenna/config/-/config-4.7.0.tgz", - "integrity": "sha512-WXx5Tsx6BBVq+QlX5Tm+HMUp+b/ft15YC4oFvdRi3Gj6HBXIcEPpw2zsdLS+Qa/TDDuwa2bYLrToBtLd8EpXpw==", + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/@athenna/config/-/config-4.8.0.tgz", + "integrity": "sha512-pTRNivg1fmViJ45237qhBiVAQU2R7iWTA28MPsJgePt0Jve0z6unhwPSBAaH/oI1KO/Ki9N3jKkwICehyT62sg==", "dev": true, "dependencies": { "dotenv": "^16.3.1", - "magicast": "^0.2.11", + "magicast": "^0.3.0", "syntax-error": "^1.4.0" }, "engines": { @@ -165,18 +184,18 @@ } }, "node_modules/@athenna/http": { - "version": "4.11.0", - "resolved": "https://registry.npmjs.org/@athenna/http/-/http-4.11.0.tgz", - "integrity": "sha512-H49Sz+Iop1iq8t4r8uKu1HMuCmgOGzRXhWQYZ6/vdpFYWIXj/ARrbJUqvlDjgCZfgu37uoYuE5EG+QsfgkdYVQ==", + "version": "4.13.0", + "resolved": "https://registry.npmjs.org/@athenna/http/-/http-4.13.0.tgz", + "integrity": "sha512-ol78x4dk9iW/qBWWsR71TBfPCvmMHceTTaBW+2M4RboYx+ymXip1LabIq/YEO+L5IpENoRt/jKJWl4szcpVsXA==", "dev": true, "engines": { "node": ">=20.0.0" } }, "node_modules/@athenna/ioc": { - "version": "4.7.0", - "resolved": "https://registry.npmjs.org/@athenna/ioc/-/ioc-4.7.0.tgz", - "integrity": "sha512-TTyNLjtNPk+P5DHmKT/IuMiNFdXKI7yMsiJyA6DSlLTZSSt8tPzbSPQYY0EvfQX19EFihiaSXX5/I+De8MUnpQ==", + "version": "4.9.0", + "resolved": "https://registry.npmjs.org/@athenna/ioc/-/ioc-4.9.0.tgz", + "integrity": "sha512-oJPWF6u0INBwuW4rAEVN5hHXIgKCA6ywvTnuWhRJnUPDU1T+4yWAxbENesydbhJpiP7ID9JSoEDA/NV9+V5wOg==", "dev": true, "dependencies": { "awilix": "^7.0.3" @@ -186,29 +205,29 @@ } }, "node_modules/@athenna/logger": { - "version": "4.8.0", - "resolved": "https://registry.npmjs.org/@athenna/logger/-/logger-4.8.0.tgz", - "integrity": "sha512-V88sEF8D/pwCmuh2zDZu+BhgL/M4e0MQrmxUvefa82//pytFuDYpNowqKFdUjPEL1zcuocskEeE0nnquOW3rIw==", + "version": "4.9.0", + "resolved": "https://registry.npmjs.org/@athenna/logger/-/logger-4.9.0.tgz", + "integrity": "sha512-RBGCZ64IH2Zw0tnmjjxOmLARHkF0WmUWSQL8TZjXZEXOM501uEPUqoW1ntRBxEOlQH1eYvPYTpZDpsblMf58gg==", "dev": true, "dependencies": { "cls-rtracer": "^2.6.3", - "telegraf": "^4.13.1" + "telegraf": "^4.15.0" }, "engines": { "node": ">=20.0.0" } }, "node_modules/@athenna/test": { - "version": "4.12.0", - "resolved": "https://registry.npmjs.org/@athenna/test/-/test-4.12.0.tgz", - "integrity": "sha512-rBEOCVXomQtVR9568L7icSQHOE+PmkVbsDjb4Ac0icICR/Nji0O4l9O7DfizSpaAttH4bB9SLhVaFBsrBQNjAw==", + "version": "4.14.0", + "resolved": "https://registry.npmjs.org/@athenna/test/-/test-4.14.0.tgz", + "integrity": "sha512-Gha600d82tROu3MNUmqHZKX913cInOc1VONiq2Z6G1ZwoWgGv32bFdTyNLsqgwPNWeWrjTN6AWI8XD/6cxkShA==", "dev": true, "dependencies": { "@japa/assert": "^1.4.1", "@japa/run-failed-tests": "^1.1.0", "@japa/runner": "^2.2.2", "@japa/spec-reporter": "^1.3.3", - "@types/sinon": "^10.0.16", + "@types/sinon": "^10.0.20", "c8": "^8.0.1", "sinon": "^15.1.0" }, @@ -217,9 +236,9 @@ } }, "node_modules/@athenna/tsconfig": { - "version": "4.9.2", - "resolved": "https://registry.npmjs.org/@athenna/tsconfig/-/tsconfig-4.9.2.tgz", - "integrity": "sha512-7+NbU5ULAX5a2yJtr1nVu1KxF+IlkbneAs+r3J1ICb01m5+s9qIxhxB/txuRhR4Rior2hNzp6lp0TSOAofzeKg==", + "version": "4.11.0", + "resolved": "https://registry.npmjs.org/@athenna/tsconfig/-/tsconfig-4.11.0.tgz", + "integrity": "sha512-MhvB9LhidQD98RXZmTl8TcJRrs6huRLJ/M9Az3sWQSHg+XR7BJ5NqrFS8FLHPtnshewl67PoY1KpcgWb0uqoZQ==", "dev": true, "dependencies": { "copyfiles": "^2.4.1", @@ -232,9 +251,9 @@ } }, "node_modules/@athenna/view": { - "version": "4.6.0", - "resolved": "https://registry.npmjs.org/@athenna/view/-/view-4.6.0.tgz", - "integrity": "sha512-K/IJNB7blaNCqvHCjFwzMgd+m6Gh1Qt1mBkUKi0KIgNFY1GHZ/GqD+/8n11RSfwReEpP0Loj42uynN+icw/ELA==", + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/@athenna/view/-/view-4.7.0.tgz", + "integrity": "sha512-gtnseNKlJyVjj2IeQ4f2kfua2gonbw9hogQL5vE4mQssBrn/meeiFFclx4RLI1RosQ3RPQfWJEnQoNF56wu4Bg==", "dev": true, "dependencies": { "edge.js": "^5.5.1" @@ -313,9 +332,9 @@ } }, "node_modules/@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", + "version": "7.23.4", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.23.4.tgz", + "integrity": "sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ==", "dev": true, "engines": { "node": ">=6.9.0" @@ -401,9 +420,9 @@ } }, "node_modules/@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", + "version": "7.23.5", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.5.tgz", + "integrity": "sha512-hOOqoiNXrmGdFbhgCzu6GiURxUgM27Xwd/aPuu8RfHEZPBzL1Z54okAHAQjXfcQNwvrlkAmAp4SlRTZ45vlthQ==", "dev": true, "bin": { "parser": "bin/babel-parser.js" @@ -413,12 +432,12 @@ } }, "node_modules/@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "version": "7.23.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.5.tgz", + "integrity": "sha512-ON5kSOJwVO6xXVRTvOI0eOnWe7VdUcIpsovGo9U/Br4Ie4UVFQTboO2cYnDhAGU6Fp+UxSiT+pMft0SMHfuq6w==", "dev": true, "dependencies": { - "@babel/helper-string-parser": "^7.22.5", + "@babel/helper-string-parser": "^7.23.4", "@babel/helper-validator-identifier": "^7.22.20", "to-fast-properties": "^2.0.0" }, @@ -808,9 +827,9 @@ "dev": true }, "node_modules/@fastify/error": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/@fastify/error/-/error-3.4.0.tgz", - "integrity": "sha512-e/mafFwbK3MNqxUcFBLgHhgxsF8UT1m8aj0dAlqEa2nJEgPsRtpHTZ3ObgrgkZ2M1eJHPTwgyUl/tXkvabsZdQ==", + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/@fastify/error/-/error-3.4.1.tgz", + "integrity": "sha512-wWSvph+29GR783IhmvdwWnN4bUxTD01Vm5Xad4i7i1VuAOItLvbPAb69sb0IQ2N57yprvhNIwAP5B6xfKTmjmQ==", "dev": true }, "node_modules/@fastify/fast-json-stringify-compiler": { @@ -1189,10 +1208,13 @@ "dev": true }, "node_modules/@ljharb/through": { - "version": "2.3.9", - "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", - "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==", + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.11.tgz", + "integrity": "sha512-ccfcIDlogiXNq5KcbAwbaO7lMh3Tm1i3khMPYpxlK8hH/W53zN81KM9coerRLOnTGu3nfXIniAmQbRI9OxbC0w==", "dev": true, + "dependencies": { + "call-bind": "^1.0.2" + }, "engines": { "node": ">= 0.4" } @@ -1578,18 +1600,18 @@ "dev": true }, "node_modules/@types/sinon": { - "version": "10.0.18", - "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.18.tgz", - "integrity": "sha512-OpQC9ug8BcnNxue2WF5aTruMaDRFn6NyfaE4DmAKOlQMn54b7CnCvDFV3wj5fk/HbSSTYmOYs2bTb5ShANjyQg==", + "version": "10.0.20", + "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-10.0.20.tgz", + "integrity": "sha512-2APKKruFNCAZgx3daAyACGzWuJ028VVCUDk6o2rw/Z4PXT0ogwdV4KUegW0MwVs0Zu59auPXbbuBJHF12Sx1Eg==", "dev": true, "dependencies": { "@types/sinonjs__fake-timers": "*" } }, "node_modules/@types/sinonjs__fake-timers": { - "version": "8.1.3", - "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.3.tgz", - "integrity": "sha512-4g+2YyWe0Ve+LBh+WUm1697PD0Kdi6coG1eU0YjQbwx61AZ8XbEpL1zIT6WjuUKrCMCROpEaYQPDjBnDouBVAQ==", + "version": "8.1.5", + "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-8.1.5.tgz", + "integrity": "sha512-mQkU2jY8jJEF7YHjHvsQO8+3ughTL1mcnn96igfhONmR+fUPSKIkefQYpSe8bsly2Ep7oQbn/6VG5/9/0qcArQ==", "dev": true }, "node_modules/@types/yargs": { @@ -2287,19 +2309,6 @@ "printable-characters": "^1.0.42" } }, - "node_modules/assert": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/assert/-/assert-2.1.0.tgz", - "integrity": "sha512-eLHpSK/Y4nhMJ07gDaAzoX/XAKS8PSaojml3M0DM4JpV1LAi5JOJ/p6H/XWrl8L+DzVEvVCW1z3vWAaB9oTsQw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "is-nan": "^1.3.2", - "object-is": "^1.1.5", - "object.assign": "^4.1.4", - "util": "^0.12.5" - } - }, "node_modules/assertion-error": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", @@ -2309,18 +2318,6 @@ "node": "*" } }, - "node_modules/ast-types": { - "version": "0.16.1", - "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.16.1.tgz", - "integrity": "sha512-6t10qk83GOG8p0vKmaCr8eiilZwO171AvbROMtvvNiwrTly62t+7XkA8RdIIVbpMhCASAsxgAzdRSwh6nw/5Dg==", - "dev": true, - "dependencies": { - "tslib": "^2.0.1" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/astral-regex": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", @@ -5115,9 +5112,9 @@ "dev": true }, "node_modules/fast-json-stringify": { - "version": "5.8.0", - "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-5.8.0.tgz", - "integrity": "sha512-VVwK8CFMSALIvt14U8AvrSzQAwN/0vaVRiFFUVlpnXSnDGrSkOAO5MtzyN8oQNjLd5AqTW5OZRgyjoNuAuR3jQ==", + "version": "5.9.1", + "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-5.9.1.tgz", + "integrity": "sha512-NMrf+uU9UJnTzfxaumMDXK1NWqtPCfGoM9DYIE+ESlaTQqjlANFBy0VAbsm6FB88Mx0nceyi18zTo5kIEUlzxg==", "dev": true, "dependencies": { "@fastify/deepmerge": "^1.0.0", @@ -5125,6 +5122,7 @@ "ajv-formats": "^2.1.1", "fast-deep-equal": "^3.1.3", "fast-uri": "^2.1.0", + "json-schema-ref-resolver": "^1.0.1", "rfdc": "^1.2.0" } }, @@ -5175,33 +5173,33 @@ } }, "node_modules/fast-uri": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-2.2.0.tgz", - "integrity": "sha512-cIusKBIt/R/oI6z/1nyfe2FvGKVTohVRfvkOhvx0nCEW+xf5NoCXjAHcWp93uOUBchzYcsvPlrapAdX1uW+YGg==", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-2.3.0.tgz", + "integrity": "sha512-eel5UKGn369gGEWOqBShmFJWfq/xSJvsgDzgLYC845GneayWvXBf0lJCBn5qTABfewy1ZDPoaR5OZCP+kssfuw==", "dev": true }, "node_modules/fastify": { - "version": "4.23.2", - "resolved": "https://registry.npmjs.org/fastify/-/fastify-4.23.2.tgz", - "integrity": "sha512-WFSxsHES115svC7NrerNqZwwM0UOxbC/P6toT9LRHgAAFvG7o2AN5W+H4ihCtOGuYXjZf4z+2jXC89rVEoPWOA==", + "version": "4.24.3", + "resolved": "https://registry.npmjs.org/fastify/-/fastify-4.24.3.tgz", + "integrity": "sha512-6HHJ+R2x2LS3y1PqxnwEIjOTZxFl+8h4kSC/TuDPXtA+v2JnV9yEtOsNSKK1RMD7sIR2y1ZsA4BEFaid/cK5pg==", "dev": true, "dependencies": { "@fastify/ajv-compiler": "^3.5.0", - "@fastify/error": "^3.2.0", + "@fastify/error": "^3.4.0", "@fastify/fast-json-stringify-compiler": "^4.3.0", "abstract-logging": "^2.0.1", "avvio": "^8.2.1", - "fast-content-type-parse": "^1.0.0", - "fast-json-stringify": "^5.7.0", - "find-my-way": "^7.6.0", - "light-my-request": "^5.9.1", - "pino": "^8.12.0", + "fast-content-type-parse": "^1.1.0", + "fast-json-stringify": "^5.8.0", + "find-my-way": "^7.7.0", + "light-my-request": "^5.11.0", + "pino": "^8.16.0", "process-warning": "^2.2.0", "proxy-addr": "^2.0.7", "rfdc": "^1.3.0", - "secure-json-parse": "^2.5.0", - "semver": "^7.5.0", - "toad-cache": "^3.2.0" + "secure-json-parse": "^2.7.0", + "semver": "^7.5.4", + "toad-cache": "^3.3.0" } }, "node_modules/fastify-plugin": { @@ -5232,9 +5230,9 @@ } }, "node_modules/figlet": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/figlet/-/figlet-1.6.0.tgz", - "integrity": "sha512-31EQGhCEITv6+hi2ORRPyn3bulaV9Fl4xOdR169cBzH/n1UqcxsiSB/noo6SJdD7Kfb1Ljit+IgR1USvF/XbdA==", + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figlet/-/figlet-1.7.0.tgz", + "integrity": "sha512-gO8l3wvqo0V7wEFLXPbkX83b7MVjRrk1oRLfYlZXol8nEpb/ON9pcKLI4qpBv5YtOTfrINtqb7b40iYY2FTWFg==", "dev": true, "bin": { "figlet": "bin/index.js" @@ -5313,9 +5311,9 @@ } }, "node_modules/find-my-way": { - "version": "7.6.2", - "resolved": "https://registry.npmjs.org/find-my-way/-/find-my-way-7.6.2.tgz", - "integrity": "sha512-0OjHn1b1nCX3eVbm9ByeEHiscPYiHLfhei1wOUU9qffQkk98wE0Lo8VrVYfSGMgnSnDh86DxedduAnBf4nwUEw==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/find-my-way/-/find-my-way-7.7.0.tgz", + "integrity": "sha512-+SrHpvQ52Q6W9f3wJoJBbAQULJuNEEQwBvlvYwACDhBTLOTMiQ0HYWh4+vC3OivGP2ENcTI1oKlFA2OepJNjhQ==", "dev": true, "dependencies": { "fast-deep-equal": "^3.1.3", @@ -6458,12 +6456,12 @@ "dev": true }, "node_modules/inquirer": { - "version": "9.2.11", - "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-9.2.11.tgz", - "integrity": "sha512-B2LafrnnhbRzCWfAdOXisUzL89Kg8cVJlYmhqoi3flSiV/TveO+nsXwgKr9h9PIo+J1hz7nBSk6gegRIMBBf7g==", + "version": "9.2.12", + "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-9.2.12.tgz", + "integrity": "sha512-mg3Fh9g2zfuVWJn6lhST0O7x4n03k7G8Tx5nvikJkbq8/CK47WDVm+UznF0G6s5Zi0KcyUisr6DU8T67N5U+1Q==", "dev": true, "dependencies": { - "@ljharb/through": "^2.3.9", + "@ljharb/through": "^2.3.11", "ansi-escapes": "^4.3.2", "chalk": "^5.3.0", "cli-cursor": "^3.1.0", @@ -6689,22 +6687,6 @@ "node": ">= 0.10" } }, - "node_modules/is-arguments": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", - "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-array-buffer": { "version": "3.0.2", "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", @@ -6855,21 +6837,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/is-generator-function": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.0.10.tgz", - "integrity": "sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A==", - "dev": true, - "dependencies": { - "has-tostringtag": "^1.0.0" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-glob": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", @@ -6927,22 +6894,6 @@ "node": ">=0.10.0" } }, - "node_modules/is-nan": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/is-nan/-/is-nan-1.3.2.tgz", - "integrity": "sha512-E+zBKpQ2t6MEo1VsonYmluk9NxGrbzpeeLC2xIViuO2EjU2xsXsBPwTr3Ykv9l08UYEVEdWeRZNouaZqF6RN0w==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.0", - "define-properties": "^1.1.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/is-negative-zero": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", @@ -7488,6 +7439,15 @@ "node": ">=6.0.0" } }, + "node_modules/json-schema-ref-resolver": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-schema-ref-resolver/-/json-schema-ref-resolver-1.0.1.tgz", + "integrity": "sha512-EJAj1pgHc1hxF6vo2Z3s69fMjO1INq6eGHXZ8Z6wCQeldCuwxGK9Sxf4/cScGn3FZubCVUehfWtcDM/PLteCQw==", + "dev": true, + "dependencies": { + "fast-deep-equal": "^3.1.3" + } + }, "node_modules/json-schema-traverse": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", @@ -8261,14 +8221,14 @@ "dev": true }, "node_modules/magicast": { - "version": "0.2.11", - "resolved": "https://registry.npmjs.org/magicast/-/magicast-0.2.11.tgz", - "integrity": "sha512-6saXbRDA1HMkqbsvHOU6HBjCVgZT460qheRkLhJQHWAbhXoWESI3Kn/dGGXyKs15FFKR85jsUqFx2sMK0wy/5g==", + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/magicast/-/magicast-0.3.2.tgz", + "integrity": "sha512-Fjwkl6a0syt9TFN0JSYpOybxiMCkYNEeOTnOTNRbjphirLakznZXAqrXgj/7GG3D1dvETONNwrBfinvAbpunDg==", "dev": true, "dependencies": { - "@babel/parser": "^7.22.16", - "@babel/types": "^7.22.17", - "recast": "^0.23.4" + "@babel/parser": "^7.23.3", + "@babel/types": "^7.23.3", + "source-map-js": "^1.0.2" } }, "node_modules/make-dir": { @@ -8719,22 +8679,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/object-is": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", - "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", - "dev": true, - "dependencies": { - "call-bind": "^1.0.2", - "define-properties": "^1.1.3" - }, - "engines": { - "node": ">= 0.4" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/object-keys": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", @@ -9268,9 +9212,9 @@ } }, "node_modules/pino": { - "version": "8.15.6", - "resolved": "https://registry.npmjs.org/pino/-/pino-8.15.6.tgz", - "integrity": "sha512-GuxHr61R0ZFD1npu58tB3a3FSVjuy21OwN/haw4OuKiZBL63Pg11Y51WWeD52RENS2mjwPZOwt+2OQOSkck6kQ==", + "version": "8.16.2", + "resolved": "https://registry.npmjs.org/pino/-/pino-8.16.2.tgz", + "integrity": "sha512-2advCDGVEvkKu9TTVSa/kWW7Z3htI/sBKEZpqiHk6ive0i/7f5b1rsU8jn0aimxqfnSz5bj/nOYkwhBUn5xxvg==", "dev": true, "dependencies": { "atomic-sleep": "^1.0.0", @@ -9282,7 +9226,7 @@ "quick-format-unescaped": "^4.0.3", "real-require": "^0.2.0", "safe-stable-stringify": "^2.3.1", - "sonic-boom": "^3.1.0", + "sonic-boom": "^3.7.0", "thread-stream": "^2.0.0" }, "bin": { @@ -9564,9 +9508,9 @@ "dev": true }, "node_modules/process-warning": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/process-warning/-/process-warning-2.2.0.tgz", - "integrity": "sha512-/1WZ8+VQjR6avWOgHeEPd7SDQmFQ1B5mC1eRXsCm5TarlNmx/wCsa5GEaxGm05BORRtyG/Ex/3xq3TuRvq57qg==", + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/process-warning/-/process-warning-2.3.2.tgz", + "integrity": "sha512-n9wh8tvBe5sFmsqlg+XQhaQLumwpqoAUruLwjCopgTmUBjJ/fjtBsJzKleCaIGBOMXYEhp1YfKl4d7rJ5ZKJGA==", "dev": true }, "node_modules/proxy-addr": { @@ -9708,22 +9652,6 @@ "node": ">= 12.13.0" } }, - "node_modules/recast": { - "version": "0.23.4", - "resolved": "https://registry.npmjs.org/recast/-/recast-0.23.4.tgz", - "integrity": "sha512-qtEDqIZGVcSZCHniWwZWbRy79Dc6Wp3kT/UmDA2RJKBPg7+7k51aQBZirHmUGn5uvHf2rg8DkjizrN26k61ATw==", - "dev": true, - "dependencies": { - "assert": "^2.0.0", - "ast-types": "^0.16.1", - "esprima": "~4.0.0", - "source-map": "~0.6.1", - "tslib": "^2.0.1" - }, - "engines": { - "node": ">= 4" - } - }, "node_modules/reflect-metadata": { "version": "0.1.13", "resolved": "https://registry.npmjs.org/reflect-metadata/-/reflect-metadata-0.1.13.tgz", @@ -10363,9 +10291,9 @@ } }, "node_modules/sonic-boom": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/sonic-boom/-/sonic-boom-3.6.0.tgz", - "integrity": "sha512-5Rs7m4IO/mW1WHouC6q6PGJsXO6hSAduwB3ltTsKaDU0Bd7sc5QEUK/jF0YL583g3BG7QV0Dg0rQNZrwZhY6Xg==", + "version": "3.7.0", + "resolved": "https://registry.npmjs.org/sonic-boom/-/sonic-boom-3.7.0.tgz", + "integrity": "sha512-IudtNvSqA/ObjN97tfgNmOKyDOs4dNcg4cUUsHDebqsgb8wGBBwb31LIgShNO8fye0dFI52X1+tFoKKI6Rq1Gg==", "dev": true, "dependencies": { "atomic-sleep": "^1.0.0" @@ -10380,6 +10308,15 @@ "node": ">=0.10.0" } }, + "node_modules/source-map-js": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", + "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/spdx-correct": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.2.0.tgz", @@ -10712,12 +10649,12 @@ } }, "node_modules/telegraf": { - "version": "4.14.0", - "resolved": "https://registry.npmjs.org/telegraf/-/telegraf-4.14.0.tgz", - "integrity": "sha512-Nn2EBsuar/Mf3SD6O9tHmJ0FyJWnwAi4rewkJMmzd/O1xWYKglEuzSnCuHHRY7oD5NJ6WNPsavta5DbED8tG3w==", + "version": "4.15.3", + "resolved": "https://registry.npmjs.org/telegraf/-/telegraf-4.15.3.tgz", + "integrity": "sha512-pm2ZQAisd0YlUvnq6xdymDfoQR++8wTalw0nfw7Tjy0va+V/0HaBLzM8kMNid8pbbt7GHTU29lEyA5CAAr8AqA==", "dev": true, "dependencies": { - "@telegraf/types": "^6.9.0", + "@telegraf/types": "^6.9.1", "abort-controller": "^3.0.0", "debug": "^4.3.4", "mri": "^1.2.0", @@ -10932,9 +10869,9 @@ } }, "node_modules/toad-cache": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/toad-cache/-/toad-cache-3.3.0.tgz", - "integrity": "sha512-3oDzcogWGHZdkwrHyvJVpPjA7oNzY6ENOV3PsWJY9XYPZ6INo94Yd47s5may1U+nleBPwDhrRiTPMIvKaa3MQg==", + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/toad-cache/-/toad-cache-3.4.1.tgz", + "integrity": "sha512-T0m3MxP3wcqW0LaV3dF1mHBU294sgYSm4FOpa5eEJaYO7PqJZBOjZEQI1y4YaKNnih1FXCEYTWDS9osCoTUefg==", "dev": true, "engines": { "node": ">=12" @@ -11250,19 +11187,6 @@ "punycode": "^2.1.0" } }, - "node_modules/util": { - "version": "0.12.5", - "resolved": "https://registry.npmjs.org/util/-/util-0.12.5.tgz", - "integrity": "sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA==", - "dev": true, - "dependencies": { - "inherits": "^2.0.3", - "is-arguments": "^1.0.4", - "is-generator-function": "^1.0.7", - "is-typed-array": "^1.1.3", - "which-typed-array": "^1.1.2" - } - }, "node_modules/util-deprecate": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", @@ -11614,9 +11538,9 @@ } }, "node_modules/youch": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/youch/-/youch-3.3.2.tgz", - "integrity": "sha512-9cwz/z7abtcHOIuH45nzmUFCZbyJA1nLqlirKvyNRx4wDMhqsBaifAJzBej7L4fsVPjFxYq3NK3GAcfvZsydFw==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/youch/-/youch-3.3.3.tgz", + "integrity": "sha512-qSFXUk3UZBLfggAW3dJKg0BMblG5biqSF8M34E06o5CSsZtH92u9Hqmj2RzGiHDi64fhe83+4tENFP2DB6t6ZA==", "dev": true, "dependencies": { "cookie": "^0.5.0", diff --git a/package.json b/package.json index c28ecaa..7890aff 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@athenna/core", - "version": "4.13.0", + "version": "4.14.0", "description": "The plug and play Node.js framework.", "license": "MIT", "author": "João Lenon ", @@ -76,15 +76,15 @@ "semver": "^7.5.4" }, "devDependencies": { - "@athenna/artisan": "^4.15.0", - "@athenna/common": "^4.18.0", - "@athenna/config": "^4.7.0", - "@athenna/http": "^4.11.0", - "@athenna/ioc": "^4.7.0", - "@athenna/logger": "^4.8.0", - "@athenna/test": "^4.12.0", - "@athenna/tsconfig": "^4.9.2", - "@athenna/view": "^4.6.0", + "@athenna/artisan": "^4.16.0", + "@athenna/common": "^4.21.0", + "@athenna/config": "^4.8.0", + "@athenna/http": "^4.12.0", + "@athenna/ioc": "^4.8.0", + "@athenna/logger": "^4.9.0", + "@athenna/test": "^4.13.0", + "@athenna/tsconfig": "^4.11.0", + "@athenna/view": "^4.7.0", "@typescript-eslint/eslint-plugin": "^6.7.4", "@typescript-eslint/parser": "^6.7.4", "commitizen": "^4.2.6", diff --git a/tests/unit/ignite/IgniteTest.ts b/tests/unit/ignite/IgniteTest.ts index ecd7034..47bbbb4 100644 --- a/tests/unit/ignite/IgniteTest.ts +++ b/tests/unit/ignite/IgniteTest.ts @@ -407,7 +407,7 @@ export default class IgniteTest { assert.calledWith(process.exit, 1) assert.calledWith(ignite.handleError, new Error('test')) - assert.calledWith(fatalMock, await new Error('test').toAthennaException().prettify()) + assert.calledOnce(fatalMock) } @Test() @@ -427,7 +427,7 @@ export default class IgniteTest { assert.calledWith(process.exit, 1) assert.calledWith(ignite.handleError, new Exception()) - assert.calledWith(fatalMock, await new Exception().prettify()) + assert.calledOnce(fatalMock) } @Test()