l.warn -> l.debug for formatter warning (#151)
* l.warn -> l.debug for formatter * Debug with function * Fix console spy
This commit is contained in:
@@ -12,7 +12,7 @@ describe('format', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
echoSpy = jest.fn(echo);
|
||||
warnSpy = jest.spyOn(console, 'warn');
|
||||
warnSpy = jest.spyOn(console, 'log');
|
||||
|
||||
formatters = new Map([
|
||||
['Address', echoSpy],
|
||||
|
||||
@@ -28,7 +28,7 @@ function formatSingleType (formatters: FormattersFunctionMap, type: Param$Types,
|
||||
const formatter = formatters.get(type);
|
||||
|
||||
if (isUndefined(formatter)) {
|
||||
l.warn(`Unable to find default formatter for '${typeToString(type)}', falling back to echo`);
|
||||
l.debug(() => `Unable to find default formatter for '${typeToString(type)}', falling back to echo`);
|
||||
|
||||
return echo(value);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user