Use standard and prettier (#10)
* switch from custom eslint config to standard + prettier * fix new standard eslint violations * add editorconfig file * auto-fix all other violations * update lint yarn script * remove jshint comment
This commit is contained in:
@ -4,29 +4,28 @@ var sinon = require('sinon');
|
||||
var expect = require('expect.js');
|
||||
var parentLog;
|
||||
|
||||
beforeEach(function () {
|
||||
beforeEach(function() {
|
||||
parentLog = new Log();
|
||||
});
|
||||
|
||||
afterEach(function () {
|
||||
afterEach(function() {
|
||||
parentLog.close();
|
||||
});
|
||||
|
||||
function makeLogger(parent, levels) {
|
||||
parent = parent || parentLog;
|
||||
var config = {
|
||||
levels: Log.parseLevels(levels || 'trace')
|
||||
levels: Log.parseLevels(levels || 'trace'),
|
||||
};
|
||||
return new ConsoleLogger(parent, config);
|
||||
}
|
||||
|
||||
require('../../utils/auto_release_stub').make();
|
||||
|
||||
describe('Console Logger', function () {
|
||||
|
||||
describe('Console Logger', function() {
|
||||
require('../generic_logger_tests')(makeLogger);
|
||||
|
||||
it('checks before using unique logging functions, falls back to #log()', function () {
|
||||
it('checks before using unique logging functions, falls back to #log()', function() {
|
||||
var _warning = console.warn;
|
||||
console.warn = null;
|
||||
sinon.stub(console, 'log');
|
||||
@ -39,5 +38,4 @@ describe('Console Logger', function () {
|
||||
console.warn = _warning;
|
||||
console.log.restore();
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user