mirror of
https://github.com/tenrok/axios.git
synced 2026-05-30 15:24:11 +03:00
12 lines
389 B
JavaScript
12 lines
389 B
JavaScript
var isURLSameOrigin = require('../../../lib/helpers/isURLSameOrigin');
|
|
|
|
describe('helpers::isURLSameOrigin', function () {
|
|
it('should detect same origin', function () {
|
|
expect(isURLSameOrigin(window.location.href)).toEqual(true);
|
|
});
|
|
|
|
it('should detect different origin', function () {
|
|
expect(isURLSameOrigin('https://github.com/mzabriskie/axios')).toEqual(false);
|
|
});
|
|
});
|