Travis build: 1837 [cron]
This commit is contained in:
2
test/isBrowser/isBrowser.js
Normal file
2
test/isBrowser/isBrowser.js
Normal file
@ -0,0 +1,2 @@
|
||||
const isBrowser = () => ![typeof window, typeof document].includes('undefined');
|
||||
module.exports = isBrowser;
|
||||
13
test/isBrowser/isBrowser.test.js
Normal file
13
test/isBrowser/isBrowser.test.js
Normal file
@ -0,0 +1,13 @@
|
||||
const test = require('tape');
|
||||
const isBrowser = require('./isBrowser.js');
|
||||
|
||||
test('Testing isBrowser', (t) => {
|
||||
//For more information on all the methods supported by tape
|
||||
//Please go to https://github.com/substack/tape
|
||||
t.true(typeof isBrowser === 'function', 'isBrowser is a Function');
|
||||
//t.deepEqual(isBrowser(args..), 'Expected');
|
||||
//t.equal(isBrowser(args..), 'Expected');
|
||||
//t.false(isBrowser(args..), 'Expected');
|
||||
//t.throws(isBrowser(args..), 'Expected');
|
||||
t.end();
|
||||
});
|
||||
Reference in New Issue
Block a user