first commit

This commit is contained in:
jefferyzhao
2025-07-31 17:44:12 +08:00
commit b9bdc8598b
42390 changed files with 4467935 additions and 0 deletions

25
node_modules/fetch-s/test/utils/buildURL.spec.js generated vendored Normal file
View File

@ -0,0 +1,25 @@
import buildURL from './../../src/utils/buildURL';
describe('test buildURL...', () => {
const origin = 'http://github.com';
it('测试url相对路径', () => {
let url = '/RekingZhang/';
let params = {
a: 1,
b: 2
};
expect(buildURL(origin, url, params)).toBe(
'http://github.com/RekingZhang/?a=1&b=2'
);
});
it('测试url为绝对路径', () => {
let url = 'https://github.com/RekingZhang/';
let params = {
a: 1,
b: 2
};
expect(buildURL(origin, url, params)).toBe(
'https://github.com/RekingZhang/?a=1&b=2'
);
});
});