logd-console-output
Advanced tools
Comparing version 1.2.0 to 1.2.1
{ | ||
"name": "logd-console-output", | ||
"version": "1.2.0", | ||
"version": "1.2.1", | ||
"description": "console output for logd", | ||
@@ -29,5 +29,5 @@ "main": "index.js", | ||
"chalk": "^2.4.1", | ||
"ee-types": "^2.1.4", | ||
"ee-types": "^2.2.0", | ||
"glob": "^7.1.2" | ||
} | ||
} |
@@ -151,3 +151,3 @@ 'use strict'; | ||
// allow custom renderer assignements | ||
// allow custom renderer assignments | ||
if (type.object(value) && value.__logd_custom_renderer) { | ||
@@ -172,3 +172,3 @@ valueType = value.__logd_custom_renderer; | ||
} else { | ||
console.log(155555555555, typeof value, Object.prototype.toString.call(value)); | ||
// just render an error | ||
@@ -175,0 +175,0 @@ this.renderers.get('error').render({ |
@@ -102,3 +102,2 @@ 'use strict'; | ||
section.test('Null', async () => { | ||
@@ -118,3 +117,3 @@ const Console = require('../'); | ||
await validator.validate([Buffer.alloc(100, 'a')], ['\u001b[90m[Buffer] (100 bytes)\u001b[39m\u001b[90m: \u001b[39m\u001b[37m0x616161616161616161616161616161616161616161616161616161616161616161616161616161616…\u001b[39m']); | ||
await validator.validate([Buffer.alloc(100, 'a')], ['\u001b[90m[Buffer] (100 bytes)\u001b[39m\u001b[90m: \u001b[39m\u001b[37m0x6161616161616161616161616161616161616161616161616161616161616161616161616161616…\u001b[39m']); | ||
}); | ||
@@ -152,3 +151,3 @@ | ||
'\u001b[90m[Function] (3 lines)\u001b[39m\u001b[90m: \u001b[39m\u001b[36mtestArrowFunction \u001b[39m\u001b[90m(parameter) => {\u001b[39m', | ||
'\u001b[90m return…\u001b[39m' | ||
'\u001b[90m r…\u001b[39m' | ||
]); | ||
@@ -369,2 +368,20 @@ }); | ||
}); | ||
section.test('Custom Class Types', async () => { | ||
const Console = require('../'); | ||
const log = new Console(); | ||
const validator = new OutputValidator(log); | ||
const X = class { | ||
get [Symbol.toStringTag]() { | ||
return 'AQL query';; | ||
} | ||
}; | ||
await validator.validate([new X()], [ | ||
'\u001b[90m[Object] (0): {\u001b[39m\u001b[90m}\u001b[39m', | ||
]); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
61706
1761
Updatedee-types@^2.2.0