You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've looked at your tests for bragi and they do not cover everything. So I tried to cover for example if a log file is actually made when a File transport is added. I checked to see if it worked and apparently it does not. Check below:
test/log.js
'use strict';
import fs from 'fs';
import logger from 'bragi';
// Logging to file.
logger.transports.add(new logger.transportClasses.File({
filename: 'test.log'
}));
describe('Log', () => {
it('logger creates a log file when a log is logged', () => {
logger.log('error', 'test log');
});
});
As you can see, it outputs via the Console transport:
Log
[ ✘ error ] test log
2016-12-09T10:58:26.283Z /home/karlm/dev/node/proj/test/log.js:20:21
✓ logger creates a log file when a log is logged
1 passing (26ms)
It however does not create the file test.log.
The text was updated successfully, but these errors were encountered:
I've looked at your tests for bragi and they do not cover everything. So I tried to cover for example if a log file is actually made when a File transport is added. I checked to see if it worked and apparently it does not. Check below:
test/log.js
test/mocha.opts:
run via npm test, in the package.json:
As you can see, it outputs via the Console transport:
It however does not create the file test.log.
The text was updated successfully, but these errors were encountered: