From 712fa894acf82334e4ab115862ad38d8664d02ca Mon Sep 17 00:00:00 2001 From: prathap-safe Date: Tue, 30 Aug 2022 12:00:04 +0530 Subject: [PATCH] Add test files to validate the functionality --- test/index.test.js | 5 +++++ test/index.test.ts | 5 +++++ 2 files changed, 10 insertions(+) create mode 100644 test/index.test.js create mode 100644 test/index.test.ts diff --git a/test/index.test.js b/test/index.test.js new file mode 100644 index 0000000..25f4b2b --- /dev/null +++ b/test/index.test.js @@ -0,0 +1,5 @@ +const logger = require("logger-safe-security").default; +const appLogger = logger.child({ service: "sample" }); + +logger.info("This is a parent logger"); +appLogger.info("This is a child logger"); \ No newline at end of file diff --git a/test/index.test.ts b/test/index.test.ts new file mode 100644 index 0000000..0991670 --- /dev/null +++ b/test/index.test.ts @@ -0,0 +1,5 @@ +import logger from "logger-safe-security"; +const appLogger = logger.child({ service: "sample" }); + +logger.info("This is a parent logger"); +appLogger.info("This is a child logger"); \ No newline at end of file