From b2569c6d9da90b81b14fb307cf84e9db8b9dd146 Mon Sep 17 00:00:00 2001 From: Gareth Jones Date: Mon, 26 Aug 2013 07:58:45 +1000 Subject: [PATCH] removed log-abspath --- 0.7-changes | 1 + test/log-abspath-test.js | 75 ---------------------------------------- 2 files changed, 1 insertion(+), 75 deletions(-) delete mode 100644 test/log-abspath-test.js diff --git a/0.7-changes b/0.7-changes index 60a3ccc..973de67 100644 --- a/0.7-changes +++ b/0.7-changes @@ -10,3 +10,4 @@ appenders now only need to provide configure function log4js.configure now only takes single argument (no options) tests use mocha not vows replaced my debug lib with tjholowaychuk's debug (more of a standard) +options.cwd removed - filenames should always be specified in full, not relative \ No newline at end of file diff --git a/test/log-abspath-test.js b/test/log-abspath-test.js deleted file mode 100644 index 20aa9de..0000000 --- a/test/log-abspath-test.js +++ /dev/null @@ -1,75 +0,0 @@ -"use strict"; -var vows = require('vows') -, assert = require('assert') -, sandbox = require('sandboxed-module'); - -vows.describe('log4js-abspath').addBatch({ - 'options': { - topic: function() { - var appenderOptions, - log4js = sandbox.require( - '../lib/log4js', - { requires: - { './appenders/fake': - { name: "fake", - appender: function() {}, - configure: function(configuration, options) { - appenderOptions = options; - return function() {}; - } - } - } - } - ), - config = { - "appenders": [ - { - "type" : "fake", - "filename" : "cheesy-wotsits.log" - } - ] - }; - - log4js.configure(config, { - cwd: '/absolute/path/to' - }); - return appenderOptions; - }, - 'should be passed to appenders during configuration': function(options) { - assert.equal(options.cwd, '/absolute/path/to'); - } - }, - - 'file appender': { - topic: function() { - var fileOpened, - fileAppender = sandbox.require( - '../lib/appenders/file', - { requires: - { '../streams': - { RollingFileStream: - function(file) { - fileOpened = file; - return { - on: function() {}, - end: function() {} - }; - } - } - } - } - ); - fileAppender.configure( - { - filename: "whatever.log", - maxLogSize: 10 - }, - { cwd: '/absolute/path/to' } - ); - return fileOpened; - }, - 'should prepend options.cwd to config.filename': function(fileOpened) { - assert.equal(fileOpened, "/absolute/path/to/whatever.log"); - } - }, -}).export(module);