Quick check to make sure the actualAppender gets the right configuration
This commit is contained in:
parent
89f3659825
commit
07e920cc1b
@ -10,6 +10,7 @@ function fancyResultingHookioAppender(opts) {
|
||||
};
|
||||
fakeLog4Js.loadAppender = function (appender) {
|
||||
fakeLog4Js.appenderMakers[appender] = function (config) {
|
||||
result.actualLoggerConfig = config;
|
||||
return function log(logEvent) {
|
||||
result.logged.push(logEvent);
|
||||
}
|
||||
@ -71,6 +72,10 @@ vows.describe('log4js hookioAppender').addBatch({
|
||||
assert.equal(result.logged[1].level.toString(), 'DEBUG');
|
||||
assert.equal(result.logged[1].data, 'OH WOW');
|
||||
assert.isTrue(typeof(result.logged[1].startTime) === 'object');
|
||||
},
|
||||
|
||||
'the actual logger should get the right config': function (result) {
|
||||
assert.equal(result.actualLoggerConfig.type, 'file');
|
||||
}
|
||||
},
|
||||
'worker': {
|
||||
|
Loading…
Reference in New Issue
Block a user