Comparing version 0.4.2 to 0.4.3
@@ -8,3 +8,3 @@ var util = require('util'), | ||
function debug(message) { | ||
util.debug(message); | ||
// util.debug(message); | ||
// console.log(message); | ||
@@ -11,0 +11,0 @@ } |
{ | ||
"name": "log4js", | ||
"version": "0.4.2", | ||
"version": "0.4.3", | ||
"description": "Port of Log4js to work with node.", | ||
@@ -30,7 +30,7 @@ "keywords": [ | ||
"async": "0.1.15", | ||
"compress-buffer": ">= 0.5.0" | ||
"compress-buffer": "0.5.1" | ||
}, | ||
"devDependencies": { | ||
"vows": ">=0.5.2", | ||
"sandboxed-module": ">= 0.1.1", | ||
"vows": "0.6.2", | ||
"sandboxed-module": "0.1.3", | ||
"hook.io": "0.7.7", | ||
@@ -37,0 +37,0 @@ "underscore": "1.2.1" |
var vows = require('vows') | ||
, fs = require('fs') | ||
, path = require('path') | ||
, log4js = require('../lib/log4js') | ||
@@ -20,3 +21,4 @@ , assert = require('assert'); | ||
topic: function() { | ||
var that = this, testFile = __dirname + '/fa-default-test.log' | ||
var that = this | ||
, testFile = path.join(__dirname, '/fa-default-test.log') | ||
, logger = log4js.getLogger('default-settings'); | ||
@@ -42,3 +44,3 @@ remove(testFile); | ||
topic: function() { | ||
var testFile = __dirname + '/fa-maxFileSize-test.log' | ||
var testFile = path.join(__dirname, '/fa-maxFileSize-test.log') | ||
, logger = log4js.getLogger('max-file-size') | ||
@@ -76,3 +78,3 @@ , that = this; | ||
topic: function() { | ||
var testFile = __dirname + '/fa-maxFileSize-with-backups-test.log' | ||
var testFile = path.join(__dirname, '/fa-maxFileSize-with-backups-test.log') | ||
, logger = log4js.getLogger('max-file-size-backups'); | ||
@@ -94,3 +96,3 @@ remove(testFile); | ||
fs.readdir(__dirname, that.callback); | ||
}, 100); | ||
}, 200); | ||
}, | ||
@@ -110,6 +112,6 @@ 'the log files': { | ||
topic: function(logFiles) { | ||
fs.readFile(logFiles[0], "utf8", this.callback); | ||
fs.readFile(path.join(__dirname, logFiles[0]), "utf8", this.callback); | ||
}, | ||
'should be the last log message': function(err, contents) { | ||
assert.include(contents, 'This is the fourth log message.'); | ||
'should be empty because the last log message triggers rolling': function(contents) { | ||
assert.isEmpty(contents); | ||
} | ||
@@ -119,6 +121,6 @@ }, | ||
topic: function(logFiles) { | ||
fs.readFile(logFiles[1], "utf8", this.callback); | ||
fs.readFile(path.join(__dirname, logFiles[1]), "utf8", this.callback); | ||
}, | ||
'should be the third log message': function(err, contents) { | ||
assert.include(contents, 'This is the third log message.'); | ||
'should be the last log message': function(contents) { | ||
assert.include(contents, 'This is the fourth log message.'); | ||
} | ||
@@ -128,6 +130,6 @@ }, | ||
topic: function(logFiles) { | ||
fs.readFile(logFiles[2], "utf8", this.callback); | ||
fs.readFile(path.join(__dirname, logFiles[2]), "utf8", this.callback); | ||
}, | ||
'should be the second log message': function(err, contents) { | ||
assert.include(contents, 'This is the second log message.'); | ||
'should be the third log message': function(contents) { | ||
assert.include(contents, 'This is the third log message.'); | ||
} | ||
@@ -134,0 +136,0 @@ } |
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
161172
49
4076
+ Addedcompress-buffer@0.5.1(transitive)
- Removedbindings@1.2.1(transitive)
- Removedcompress-buffer@1.2.2(transitive)
Updatedcompress-buffer@0.5.1