diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index fba5787..33d0647 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: '14.x' + node-version: '18.x' registry-url: 'https://registry.npmjs.org' - name: Install dependencies @@ -25,10 +25,16 @@ jobs: run: npm run build - name: Copy README to build - run: cp README.md build/README.md + run: cp README.md build/README.md | true - name: Copy LICENSE to build - run: cp LICENSE.md build/LICENSE.md + run: cp LICENSE.md build/LICENSE.md | true + + - name: Copy templates to build + run: cp -r templates build/templates | true + + - name: Copy configurer to build + run: cp -r configurer build/configurer | true - name: Automatic GitHub Release uses: justincy/github-action-npm-release@2.0.1 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c89def6..5a1642e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,17 +9,6 @@ on: - develop jobs: - qodana: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - name: 'Qodana Scan' - uses: JetBrains/qodana-action@main - env: - QODANA_TOKEN: ${{ secrets.QODANA_TOKEN }} - linux: runs-on: ubuntu-latest strategy: diff --git a/.gitignore b/.gitignore index 4b6c558..d0a5509 100644 --- a/.gitignore +++ b/.gitignore @@ -115,14 +115,14 @@ out .pnp.* # Compiled code -./dist -./build +dist +build *.js *.d.ts *.js.map -!tests/Stubs/**/*.js -!tests/Stubs/**/*.d.ts -!tests/Stubs/**/*.js.map +!tests/stubs/**/*.js +!tests/stubs/**/*.d.ts +!tests/stubs/**/*.js.map # IDE .idea diff --git a/package-lock.json b/package-lock.json index 0d0d0d6..241551d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,22 +1,22 @@ { "name": "@athenna/logger", - "version": "4.1.0", + "version": "4.2.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@athenna/logger", - "version": "4.1.0", + "version": "4.2.0", "license": "MIT", "dependencies": { "cls-rtracer": "^2.6.3", "telegraf": "^4.12.2" }, "devDependencies": { - "@athenna/common": "^4.2.0", - "@athenna/config": "^4.2.0", - "@athenna/ioc": "^4.0.0", - "@athenna/test": "^4.2.0", + "@athenna/common": "^4.4.0", + "@athenna/config": "^4.3.0", + "@athenna/ioc": "^4.1.0", + "@athenna/test": "^4.3.0", "@typescript-eslint/eslint-plugin": "^5.56.0", "@typescript-eslint/parser": "^5.56.0", "c8": "^7.12.0", @@ -67,18 +67,18 @@ "dev": true }, "node_modules/@athenna/common": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@athenna/common/-/common-4.2.0.tgz", - "integrity": "sha512-NT7lrNpW2WqKT6TyXJAysfFT3w6IfyaRdivDRzsSk6/lz0nq8pjZhITP9EUK10mdhmjBYTBcMCVO1JR3j1GZ4w==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/@athenna/common/-/common-4.5.0.tgz", + "integrity": "sha512-/Va3PtDRAR/FdfRuGYmuUXPGuOikqmXtGOENWVVbcHVu0PaXkZ8P9bqWngbyfBV+R2O0g2UVyzEXS7M6NP0JMg==", "dev": true, "dependencies": { "@fastify/formbody": "^7.4.0", "bytes": "^3.1.2", "callsite": "^1.0.0", - "chalk": "^5.2.0", + "chalk": "^5.3.0", "change-case": "^4.1.2", "collect.js": "^4.36.1", - "fastify": "^4.16.3", + "fastify": "^4.21.0", "got": "^12.6.1", "http-status-codes": "^2.2.0", "is-wsl": "^2.2.0", @@ -93,13 +93,13 @@ "uuid": "^8.3.2", "validator-brazil": "^1.2.2", "youch": "^3.2.3", - "youch-terminal": "^2.2.0" + "youch-terminal": "^2.2.1" } }, "node_modules/@athenna/config": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@athenna/config/-/config-4.2.0.tgz", - "integrity": "sha512-hUeoIZp7NnigATnhgNqDUjf73TbIKo5+mLQdN0WIUZWmtBMFy7c8NiNDEgxp4ZQNCCt2N3jgtqOE2BsiRaNPPw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@athenna/config/-/config-4.3.0.tgz", + "integrity": "sha512-UHSze3yy1avM4cC9TEmzdZ6s/ZAscWR/koThTnk6MOlaDApGGNrlbLZ1umOl21zxxfNm4+DZHzAhJxeuMkpdwg==", "dev": true, "dependencies": { "dotenv": "^16.3.1", @@ -108,18 +108,18 @@ } }, "node_modules/@athenna/ioc": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@athenna/ioc/-/ioc-4.0.0.tgz", - "integrity": "sha512-/akqOOOa++OE8fwESt113IcdWjauoWI0w7kv+COnk0zijSHsNkIxtBqJPOBo/8JJhj5iBHnzM67ZM4af9ae4TQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@athenna/ioc/-/ioc-4.1.0.tgz", + "integrity": "sha512-NSKi2QYSiQ2d+WxqdJf9reivIkCGQ0UQcsPZvaSi/kBOdqEXgxYbsx+9h7aJ8wWFVPbksQhRkIvW1rJYS4mfQw==", "dev": true, "dependencies": { "awilix": "^7.0.3" } }, "node_modules/@athenna/test": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@athenna/test/-/test-4.2.0.tgz", - "integrity": "sha512-PgyXCK+sQ1ZwsgfzEGuQmuMmfN1GpLuHguSTUE/MbkiHgZFkbl30I+E1lheIJ7KwWMTwtG3/4k+1T7U9UFuOnA==", + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/@athenna/test/-/test-4.4.0.tgz", + "integrity": "sha512-cMWz2ws9YbHD0EUGgeQpivaOnQOUQa2vglNPHNPkWNaBJimPm1dpX2tq/af2hYybD2FGmEqND5BP21YSRjBxdw==", "dev": true, "dependencies": { "@japa/assert": "^1.4.1", @@ -2642,9 +2642,9 @@ } }, "node_modules/chalk": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.2.0.tgz", - "integrity": "sha512-ree3Gqw/nazQAPuJJEy+avdl7QfZMcUvmHIKgEZkGL+xOBzRvup5Hxo6LHuMceSxOabuJLJm5Yp/92R9eMmMvA==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz", + "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==", "dev": true, "engines": { "node": "^12.17.0 || ^14.13 || >=16.0.0" @@ -4279,9 +4279,9 @@ "dev": true }, "node_modules/fast-json-stringify": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-5.7.0.tgz", - "integrity": "sha512-sBVPTgnAZseLu1Qgj6lUbQ0HfjFhZWXAmpZ5AaSGkyLh5gAXBga/uPJjQPHpDFjC9adWIpdOcCLSDTgrZ7snoQ==", + "version": "5.8.0", + "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-5.8.0.tgz", + "integrity": "sha512-VVwK8CFMSALIvt14U8AvrSzQAwN/0vaVRiFFUVlpnXSnDGrSkOAO5MtzyN8oQNjLd5AqTW5OZRgyjoNuAuR3jQ==", "dev": true, "dependencies": { "@fastify/deepmerge": "^1.0.0", @@ -4330,9 +4330,9 @@ } }, "node_modules/fast-redact": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/fast-redact/-/fast-redact-3.2.0.tgz", - "integrity": "sha512-zaTadChr+NekyzallAMXATXLOR8MNx3zqpZ0MUF2aGf4EathnG0f32VLODNlY8IuGY3HoRO2L6/6fSzNsLaHIw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/fast-redact/-/fast-redact-3.3.0.tgz", + "integrity": "sha512-6T5V1QK1u4oF+ATxs1lWUmlEk6P2T9HqJG3e2DnHOdVgZy2rFJBoEnrIedcTXlkAHU/zKC+7KETJ+KGGKwxgMQ==", "dev": true, "engines": { "node": ">=6" @@ -4345,9 +4345,9 @@ "dev": true }, "node_modules/fastify": { - "version": "4.20.0", - "resolved": "https://registry.npmjs.org/fastify/-/fastify-4.20.0.tgz", - "integrity": "sha512-zWWi5KGAb1YZ6fyrnFnA1CA1EZHkGM6YuELgB3QpS3l4lLRy14W1cc16b4KGPH/zQ98WCSdS+T41JkHY3eq1oA==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/fastify/-/fastify-4.21.0.tgz", + "integrity": "sha512-tsu4bcwE4HetxqW8prA5fbC9bKHMYDp7jGEDWyzK1l90a3uOaLoIcQbdGcWeODNLVJviQnzh1wvIjTZE3MJFEg==", "dev": true, "dependencies": { "@fastify/ajv-compiler": "^3.5.0", @@ -7659,9 +7659,9 @@ } }, "node_modules/pino": { - "version": "8.14.1", - "resolved": "https://registry.npmjs.org/pino/-/pino-8.14.1.tgz", - "integrity": "sha512-8LYNv7BKWXSfS+k6oEc6occy5La+q2sPwU3q2ljTX5AZk7v+5kND2o5W794FyRaqha6DJajmkNRsWtPpFyMUdw==", + "version": "8.15.0", + "resolved": "https://registry.npmjs.org/pino/-/pino-8.15.0.tgz", + "integrity": "sha512-olUADJByk4twxccmAxb1RiGKOSvddHugCV3wkqjyv+3Sooa2KLrmXrKEWOKi0XPCLasRR5jBXxioE1jxUa4KzQ==", "dev": true, "dependencies": { "atomic-sleep": "^1.0.0", @@ -9676,9 +9676,9 @@ } }, "node_modules/youch-terminal": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/youch-terminal/-/youch-terminal-2.2.0.tgz", - "integrity": "sha512-LLYtvG/4XoRO/vhf2eBkzT6dI1hWliLSp7NuXRKsvBAITuIxODS61X7AQOHl5Aaf8oquS9JlHSpjTFjX140XKA==", + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/youch-terminal/-/youch-terminal-2.2.2.tgz", + "integrity": "sha512-JfVAsD0r88+vWVz+Im6bMk+c7gErDp1lq6Z1Na5LAyPZTwhB3VgO6HUQsm83I217mRFSuwVwEpnvwkK/TDTNhQ==", "dev": true, "dependencies": { "kleur": "^4.1.5", @@ -9733,18 +9733,18 @@ "dev": true }, "@athenna/common": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@athenna/common/-/common-4.2.0.tgz", - "integrity": "sha512-NT7lrNpW2WqKT6TyXJAysfFT3w6IfyaRdivDRzsSk6/lz0nq8pjZhITP9EUK10mdhmjBYTBcMCVO1JR3j1GZ4w==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/@athenna/common/-/common-4.5.0.tgz", + "integrity": "sha512-/Va3PtDRAR/FdfRuGYmuUXPGuOikqmXtGOENWVVbcHVu0PaXkZ8P9bqWngbyfBV+R2O0g2UVyzEXS7M6NP0JMg==", "dev": true, "requires": { "@fastify/formbody": "^7.4.0", "bytes": "^3.1.2", "callsite": "^1.0.0", - "chalk": "^5.2.0", + "chalk": "^5.3.0", "change-case": "^4.1.2", "collect.js": "^4.36.1", - "fastify": "^4.16.3", + "fastify": "^4.21.0", "got": "^12.6.1", "http-status-codes": "^2.2.0", "is-wsl": "^2.2.0", @@ -9759,13 +9759,13 @@ "uuid": "^8.3.2", "validator-brazil": "^1.2.2", "youch": "^3.2.3", - "youch-terminal": "^2.2.0" + "youch-terminal": "^2.2.1" } }, "@athenna/config": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@athenna/config/-/config-4.2.0.tgz", - "integrity": "sha512-hUeoIZp7NnigATnhgNqDUjf73TbIKo5+mLQdN0WIUZWmtBMFy7c8NiNDEgxp4ZQNCCt2N3jgtqOE2BsiRaNPPw==", + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/@athenna/config/-/config-4.3.0.tgz", + "integrity": "sha512-UHSze3yy1avM4cC9TEmzdZ6s/ZAscWR/koThTnk6MOlaDApGGNrlbLZ1umOl21zxxfNm4+DZHzAhJxeuMkpdwg==", "dev": true, "requires": { "dotenv": "^16.3.1", @@ -9774,18 +9774,18 @@ } }, "@athenna/ioc": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@athenna/ioc/-/ioc-4.0.0.tgz", - "integrity": "sha512-/akqOOOa++OE8fwESt113IcdWjauoWI0w7kv+COnk0zijSHsNkIxtBqJPOBo/8JJhj5iBHnzM67ZM4af9ae4TQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/@athenna/ioc/-/ioc-4.1.0.tgz", + "integrity": "sha512-NSKi2QYSiQ2d+WxqdJf9reivIkCGQ0UQcsPZvaSi/kBOdqEXgxYbsx+9h7aJ8wWFVPbksQhRkIvW1rJYS4mfQw==", "dev": true, "requires": { "awilix": "^7.0.3" } }, "@athenna/test": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/@athenna/test/-/test-4.2.0.tgz", - "integrity": "sha512-PgyXCK+sQ1ZwsgfzEGuQmuMmfN1GpLuHguSTUE/MbkiHgZFkbl30I+E1lheIJ7KwWMTwtG3/4k+1T7U9UFuOnA==", + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/@athenna/test/-/test-4.4.0.tgz", + "integrity": "sha512-cMWz2ws9YbHD0EUGgeQpivaOnQOUQa2vglNPHNPkWNaBJimPm1dpX2tq/af2hYybD2FGmEqND5BP21YSRjBxdw==", "dev": true, "requires": { "@japa/assert": "^1.4.1", @@ -11687,9 +11687,9 @@ } }, "chalk": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.2.0.tgz", - "integrity": "sha512-ree3Gqw/nazQAPuJJEy+avdl7QfZMcUvmHIKgEZkGL+xOBzRvup5Hxo6LHuMceSxOabuJLJm5Yp/92R9eMmMvA==", + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz", + "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==", "dev": true }, "change-case": { @@ -12915,9 +12915,9 @@ "dev": true }, "fast-json-stringify": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-5.7.0.tgz", - "integrity": "sha512-sBVPTgnAZseLu1Qgj6lUbQ0HfjFhZWXAmpZ5AaSGkyLh5gAXBga/uPJjQPHpDFjC9adWIpdOcCLSDTgrZ7snoQ==", + "version": "5.8.0", + "resolved": "https://registry.npmjs.org/fast-json-stringify/-/fast-json-stringify-5.8.0.tgz", + "integrity": "sha512-VVwK8CFMSALIvt14U8AvrSzQAwN/0vaVRiFFUVlpnXSnDGrSkOAO5MtzyN8oQNjLd5AqTW5OZRgyjoNuAuR3jQ==", "dev": true, "requires": { "@fastify/deepmerge": "^1.0.0", @@ -12964,9 +12964,9 @@ } }, "fast-redact": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/fast-redact/-/fast-redact-3.2.0.tgz", - "integrity": "sha512-zaTadChr+NekyzallAMXATXLOR8MNx3zqpZ0MUF2aGf4EathnG0f32VLODNlY8IuGY3HoRO2L6/6fSzNsLaHIw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/fast-redact/-/fast-redact-3.3.0.tgz", + "integrity": "sha512-6T5V1QK1u4oF+ATxs1lWUmlEk6P2T9HqJG3e2DnHOdVgZy2rFJBoEnrIedcTXlkAHU/zKC+7KETJ+KGGKwxgMQ==", "dev": true }, "fast-uri": { @@ -12976,9 +12976,9 @@ "dev": true }, "fastify": { - "version": "4.20.0", - "resolved": "https://registry.npmjs.org/fastify/-/fastify-4.20.0.tgz", - "integrity": "sha512-zWWi5KGAb1YZ6fyrnFnA1CA1EZHkGM6YuELgB3QpS3l4lLRy14W1cc16b4KGPH/zQ98WCSdS+T41JkHY3eq1oA==", + "version": "4.21.0", + "resolved": "https://registry.npmjs.org/fastify/-/fastify-4.21.0.tgz", + "integrity": "sha512-tsu4bcwE4HetxqW8prA5fbC9bKHMYDp7jGEDWyzK1l90a3uOaLoIcQbdGcWeODNLVJviQnzh1wvIjTZE3MJFEg==", "dev": true, "requires": { "@fastify/ajv-compiler": "^3.5.0", @@ -15449,9 +15449,9 @@ "dev": true }, "pino": { - "version": "8.14.1", - "resolved": "https://registry.npmjs.org/pino/-/pino-8.14.1.tgz", - "integrity": "sha512-8LYNv7BKWXSfS+k6oEc6occy5La+q2sPwU3q2ljTX5AZk7v+5kND2o5W794FyRaqha6DJajmkNRsWtPpFyMUdw==", + "version": "8.15.0", + "resolved": "https://registry.npmjs.org/pino/-/pino-8.15.0.tgz", + "integrity": "sha512-olUADJByk4twxccmAxb1RiGKOSvddHugCV3wkqjyv+3Sooa2KLrmXrKEWOKi0XPCLasRR5jBXxioE1jxUa4KzQ==", "dev": true, "requires": { "atomic-sleep": "^1.0.0", @@ -16968,9 +16968,9 @@ } }, "youch-terminal": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/youch-terminal/-/youch-terminal-2.2.0.tgz", - "integrity": "sha512-LLYtvG/4XoRO/vhf2eBkzT6dI1hWliLSp7NuXRKsvBAITuIxODS61X7AQOHl5Aaf8oquS9JlHSpjTFjX140XKA==", + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/youch-terminal/-/youch-terminal-2.2.2.tgz", + "integrity": "sha512-JfVAsD0r88+vWVz+Im6bMk+c7gErDp1lq6Z1Na5LAyPZTwhB3VgO6HUQsm83I217mRFSuwVwEpnvwkK/TDTNhQ==", "dev": true, "requires": { "kleur": "^4.1.5", diff --git a/package.json b/package.json index be3250e..eb96f62 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@athenna/logger", - "version": "4.1.0", + "version": "4.2.0", "description": "The Athenna logging solution. Log in stdout, files and buckets.", "license": "MIT", "author": "João Lenon ", @@ -32,7 +32,8 @@ "src/*.d.ts", "src/**/*.js", "src/**/*.d.ts", - "templates" + "templates", + "configurer" ], "type": "module", "main": "./src/index.js", @@ -58,10 +59,10 @@ "cls-rtracer": "^2.6.3" }, "devDependencies": { - "@athenna/common": "^4.2.0", - "@athenna/config": "^4.2.0", - "@athenna/ioc": "^4.0.0", - "@athenna/test": "^4.2.0", + "@athenna/common": "^4.4.0", + "@athenna/config": "^4.3.0", + "@athenna/ioc": "^4.1.0", + "@athenna/test": "^4.3.0", "@typescript-eslint/eslint-plugin": "^5.56.0", "@typescript-eslint/parser": "^5.56.0", "c8": "^7.12.0", diff --git a/src/index.ts b/src/index.ts index 6b0321a..b418e11 100644 --- a/src/index.ts +++ b/src/index.ts @@ -7,11 +7,11 @@ * file that was distributed with this source code. */ -export * from './facades/Log.js' -export * from './logger/Logger.js' -export * from './drivers/Driver.js' -export * from './formatters/Formatter.js' -export * from './helpers/FactoryHelper.js' -export * from './factories/DriverFactory.js' -export * from './providers/LoggerProvider.js' -export * from './factories/FormatterFactory.js' +export * from '#src/facades/Log' +export * from '#src/logger/Logger' +export * from '#src/drivers/Driver' +export * from '#src/formatters/Formatter' +export * from '#src/helpers/FactoryHelper' +export * from '#src/factories/DriverFactory' +export * from '#src/providers/LoggerProvider' +export * from '#src/factories/FormatterFactory' diff --git a/tests/unit/drivers/ConsoleDriverTest.ts b/tests/unit/drivers/ConsoleDriverTest.ts index 13457df..2085f9b 100644 --- a/tests/unit/drivers/ConsoleDriverTest.ts +++ b/tests/unit/drivers/ConsoleDriverTest.ts @@ -7,9 +7,8 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' import { Path, Exec } from '@athenna/common' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' export default class ConsoleDriverTest { @Test() diff --git a/tests/unit/drivers/DiscordDriverTest.ts b/tests/unit/drivers/DiscordDriverTest.ts index 154150d..d224fe6 100644 --- a/tests/unit/drivers/DiscordDriverTest.ts +++ b/tests/unit/drivers/DiscordDriverTest.ts @@ -10,8 +10,7 @@ import { Path } from '@athenna/common' import { Config } from '@athenna/config' import { Log, LoggerProvider } from '#src' -import type { Context } from '@athenna/test/types' -import { Test, AfterEach, BeforeEach } from '@athenna/test' +import { Test, AfterEach, BeforeEach, type Context } from '@athenna/test' export default class DiscordDriverTest { @BeforeEach() diff --git a/tests/unit/drivers/FileDriverTest.ts b/tests/unit/drivers/FileDriverTest.ts index 8a4224f..496ab53 100644 --- a/tests/unit/drivers/FileDriverTest.ts +++ b/tests/unit/drivers/FileDriverTest.ts @@ -9,9 +9,8 @@ import { Config } from '@athenna/config' import { Log, LoggerProvider } from '#src' -import type { Context } from '@athenna/test/types' import { File, Folder, Path } from '@athenna/common' -import { Test, AfterEach, BeforeEach } from '@athenna/test' +import { Test, AfterEach, BeforeEach, type Context } from '@athenna/test' export default class FileDriverTest { @BeforeEach() diff --git a/tests/unit/drivers/SlackDriverTest.ts b/tests/unit/drivers/SlackDriverTest.ts index 8b2f3aa..84fe101 100644 --- a/tests/unit/drivers/SlackDriverTest.ts +++ b/tests/unit/drivers/SlackDriverTest.ts @@ -10,8 +10,7 @@ import { Path } from '@athenna/common' import { Config } from '@athenna/config' import { Log, LoggerProvider } from '#src' -import type { Context } from '@athenna/test/types' -import { AfterEach, BeforeEach, Test, Timeout } from '@athenna/test' +import { Test, Timeout, AfterEach, BeforeEach, type Context } from '@athenna/test' export default class SlackDriverTest { @BeforeEach() diff --git a/tests/unit/drivers/StackDriverTest.ts b/tests/unit/drivers/StackDriverTest.ts index 14ed31d..ba0b726 100644 --- a/tests/unit/drivers/StackDriverTest.ts +++ b/tests/unit/drivers/StackDriverTest.ts @@ -10,8 +10,7 @@ import { Path } from '@athenna/common' import { Config } from '@athenna/config' import { Log, LoggerProvider } from '#src' -import type { Context } from '@athenna/test/types' -import { AfterEach, BeforeEach, Test, Timeout } from '@athenna/test' +import { Test, Timeout, AfterEach, BeforeEach, type Context } from '@athenna/test' export default class StackDriverTest { @BeforeEach() diff --git a/tests/unit/drivers/TelegramDriverTest.ts b/tests/unit/drivers/TelegramDriverTest.ts index 0d26207..cbc32db 100644 --- a/tests/unit/drivers/TelegramDriverTest.ts +++ b/tests/unit/drivers/TelegramDriverTest.ts @@ -10,8 +10,7 @@ import { Path } from '@athenna/common' import { Config } from '@athenna/config' import { Log, LoggerProvider } from '#src' -import type { Context } from '@athenna/test/types' -import { AfterEach, BeforeEach, Test, Timeout } from '@athenna/test' +import { Test, Timeout, AfterEach, BeforeEach, type Context } from '@athenna/test' export default class TelegramDriverTest { @BeforeEach() diff --git a/tests/unit/factories/DriverFactoryTest.ts b/tests/unit/factories/DriverFactoryTest.ts index 75048a2..263b1d4 100644 --- a/tests/unit/factories/DriverFactoryTest.ts +++ b/tests/unit/factories/DriverFactoryTest.ts @@ -8,16 +8,14 @@ */ import { Config } from '@athenna/config' -import { ObjectBuilder, Path } from '@athenna/common' - import { Driver, DriverFactory } from '#src' -import type { Context } from '@athenna/test/types' -import { AfterEach, BeforeEach, Test } from '@athenna/test' +import { FileDriver } from '#src/drivers/FileDriver' +import { ObjectBuilder, Path } from '@athenna/common' +import { ConsoleDriver } from '#src/drivers/ConsoleDriver' +import { Test, AfterEach, BeforeEach, type Context } from '@athenna/test' import { DriverExistException } from '#src/exceptions/DriverExistException' import { NotFoundDriverException } from '#src/exceptions/NotFoundDriverException' import { NotImplementedConfigException } from '#src/exceptions/NotImplementedConfigException' -import { ConsoleDriver } from '#src/drivers/ConsoleDriver' -import { FileDriver } from '#src/drivers/FileDriver' class CustomDriver extends Driver { public transport(level: string, message: any): any { diff --git a/tests/unit/factories/FormatterFactoryTest.ts b/tests/unit/factories/FormatterFactoryTest.ts index 26fd49d..9e27dc5 100644 --- a/tests/unit/factories/FormatterFactoryTest.ts +++ b/tests/unit/factories/FormatterFactoryTest.ts @@ -7,9 +7,8 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' +import { Test, type Context } from '@athenna/test' import { Formatter, FormatterFactory } from '#src' -import type { Context } from '@athenna/test/types' import { FormatterExistException } from '#src/exceptions/FormatterExistException' import { NotFoundFormatterException } from '#src/exceptions/NotFoundFormatterException' diff --git a/tests/unit/formatters/CliFormatterTest.ts b/tests/unit/formatters/CliFormatterTest.ts index 9b642dd..cbdf421 100644 --- a/tests/unit/formatters/CliFormatterTest.ts +++ b/tests/unit/formatters/CliFormatterTest.ts @@ -7,8 +7,7 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' import { CliFormatter } from '#src/formatters/CliFormatter' export default class CliFormatterTest { diff --git a/tests/unit/formatters/JsonFormatterTest.ts b/tests/unit/formatters/JsonFormatterTest.ts index 9d43c45..ac405c8 100644 --- a/tests/unit/formatters/JsonFormatterTest.ts +++ b/tests/unit/formatters/JsonFormatterTest.ts @@ -8,9 +8,8 @@ */ import { Is } from '@athenna/common' -import { Test } from '@athenna/test' import { runWithId } from 'cls-rtracer' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' import { JsonFormatter } from '#src/formatters/JsonFormatter' export default class JsonFormatterTest { diff --git a/tests/unit/formatters/MessageFormatterTest.ts b/tests/unit/formatters/MessageFormatterTest.ts index e2d3fe9..d6172ad 100644 --- a/tests/unit/formatters/MessageFormatterTest.ts +++ b/tests/unit/formatters/MessageFormatterTest.ts @@ -8,8 +8,7 @@ */ import { hostname } from 'node:os' -import { Test } from '@athenna/test' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' import { MessageFormatter } from '#src/formatters/MessageFormatter' export default class MessageFormatterTest { diff --git a/tests/unit/formatters/NoneFormatterTest.ts b/tests/unit/formatters/NoneFormatterTest.ts index b35ca26..2ede371 100644 --- a/tests/unit/formatters/NoneFormatterTest.ts +++ b/tests/unit/formatters/NoneFormatterTest.ts @@ -7,9 +7,8 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' import { Color } from '@athenna/common' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' import { NoneFormatter } from '#src/formatters/NoneFormatter' export default class NoneFormatterTest { diff --git a/tests/unit/formatters/RequestFormatterTest.ts b/tests/unit/formatters/RequestFormatterTest.ts index d82bc6d..58ca7e2 100644 --- a/tests/unit/formatters/RequestFormatterTest.ts +++ b/tests/unit/formatters/RequestFormatterTest.ts @@ -7,8 +7,7 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' import { RequestFormatter } from '#src/formatters/RequestFormatter' export default class RequestFormatterTest { diff --git a/tests/unit/formatters/SimpleFormatterTest.ts b/tests/unit/formatters/SimpleFormatterTest.ts index 1bc789e..f19692a 100644 --- a/tests/unit/formatters/SimpleFormatterTest.ts +++ b/tests/unit/formatters/SimpleFormatterTest.ts @@ -7,8 +7,7 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' import { SimpleFormatter } from '#src/formatters/SimpleFormatter' export default class SimpleFormatterTest { diff --git a/tests/unit/logger/LoggerTest.ts b/tests/unit/logger/LoggerTest.ts index d5b196d..32576a0 100644 --- a/tests/unit/logger/LoggerTest.ts +++ b/tests/unit/logger/LoggerTest.ts @@ -7,9 +7,8 @@ * file that was distributed with this source code. */ -import { Test } from '@athenna/test' import { Exec, Path } from '@athenna/common' -import type { Context } from '@athenna/test/types' +import { Test, type Context } from '@athenna/test' export default class LoggerTest { @Test()