Sha256: 857f7afe3e04750005ad5ca2ed5e9e4845e74036f077e95fb8503db95bf4726f
Contents?: true
Size: 806 Bytes
Versions: 17
Compression:
Stored size: 806 Bytes
Contents
"use strict"; var assert = require('assert') , vows = require('vows') , layouts = require('../lib/layouts') , sandbox = require('sandboxed-module'); vows.describe('../lib/appenders/console').addBatch({ 'appender': { topic: function() { var messages = [] , fakeConsole = { log: function(msg) { messages.push(msg); } } , appenderModule = sandbox.require( '../lib/appenders/console', { globals: { 'console': fakeConsole } } ) , appender = appenderModule.appender(layouts.messagePassThroughLayout); appender({ data: ["blah"] }); return messages; }, 'should output to console': function(messages) { assert.equal(messages[0], 'blah'); } } }).exportTo(module);
Version data entries
17 entries across 17 versions & 2 rubygems