-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(package): update eslint-config-dustinspecker to version 0.3.1
- Loading branch information
1 parent
6f315e1
commit 5d2ebdd
Showing
6 changed files
with
48 additions
and
184 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,26 @@ | ||
/* global describe, it */ | ||
'use strict'; | ||
import {expect} from 'chai'; | ||
import isJsType from '../lib/'; | ||
'use strict' | ||
import {expect} from 'chai' | ||
import isJsType from '../lib/' | ||
|
||
describe('is-js-type', () => { | ||
it('should throw TypeError if type is not a string', () => { | ||
function test() { | ||
isJsType(); | ||
} | ||
|
||
expect(test).to.throw(TypeError, /Expected type to be a string/); | ||
}); | ||
const test = () => isJsType() | ||
expect(test).to.throw(TypeError, /Expected type to be a string/) | ||
}) | ||
|
||
it('should return false for non js types', () => { | ||
expect(isJsType('gulp')).to.eql(false); | ||
expect(isJsType('cat')).to.eql(false); | ||
}); | ||
expect(isJsType('gulp')).to.eql(false) | ||
expect(isJsType('cat')).to.eql(false) | ||
}) | ||
|
||
it('should return true for js types', () => { | ||
expect(isJsType('Array')).to.eql(true); | ||
expect(isJsType('Error')).to.eql(true); | ||
}); | ||
expect(isJsType('Array')).to.eql(true) | ||
expect(isJsType('Error')).to.eql(true) | ||
}) | ||
|
||
it('should be case insensitive', () => { | ||
expect(isJsType('array')).to.eql(true); | ||
expect(isJsType('ARRAY')).to.eql(true); | ||
}); | ||
}); | ||
expect(isJsType('array')).to.eql(true) | ||
expect(isJsType('ARRAY')).to.eql(true) | ||
}) | ||
}) |