more linting

This commit is contained in:
Gareth Jones 2013-05-27 07:44:59 +10:00
parent 7cb7e6df72
commit 1ad4977aec

View File

@ -1,3 +1,4 @@
"use strict";
var vows = require('vows') var vows = require('vows')
, fs = require('fs') , fs = require('fs')
, assert = require('assert'); , assert = require('assert');
@ -15,7 +16,15 @@ vows.describe('log4js logLevelFilter').addBatch({
topic: function() { topic: function() {
var log4js = require('../lib/log4js'), logEvents = [], logger; var log4js = require('../lib/log4js'), logEvents = [], logger;
log4js.clearAppenders(); log4js.clearAppenders();
log4js.addAppender(require('../lib/appenders/logLevelFilter').appender('ERROR', function(evt) { logEvents.push(evt); }), "logLevelTest"); log4js.addAppender(
require('../lib/appenders/logLevelFilter')
.appender(
'ERROR',
function(evt) { logEvents.push(evt); }
),
"logLevelTest"
);
logger = log4js.getLogger("logLevelTest"); logger = log4js.getLogger("logLevelTest");
logger.debug('this should not trigger an event'); logger.debug('this should not trigger an event');
logger.warn('neither should this'); logger.warn('neither should this');