Files
30-seconds-of-code/test/currentURL.test.js
2018-10-31 20:00:32 +02:00

10 lines
285 B
JavaScript

const expect = require('expect');
const {currentURL} = require('./_30s.js');
test('currentURL is a Function', () => {
expect(currentURL).toBeInstanceOf(Function);
});
test('currentURL returns the appropriate value', () => {
expect(currentURL()).toEqual(global.location.href);
});