diff --git a/pages/API/download-file/download-file.uvue b/pages/API/download-file/download-file.uvue index 55a0b9c395e08aa8bde9a6ee8361de64387800b6..5e719754b37d2fe6af31206e224578e4b979949e 100644 --- a/pages/API/download-file/download-file.uvue +++ b/pages/API/download-file/download-file.uvue @@ -73,7 +73,7 @@ jest_set_cookie(){ uni.request({ - url: "http://request.dcloud.net.cn/api/http/header/setCookie", + url: "https://request.dcloud.net.cn/api/http/header/setCookie", method: "GET", timeout: 6000, sslVerify: false, @@ -90,7 +90,7 @@ jest_delete_cookie(){ uni.request({ - url: "http://request.dcloud.net.cn/api/http/header/deleteCookie", + url: "https://request.dcloud.net.cn/api/http/header/deleteCookie", method: "GET", timeout: 6000, sslVerify: false, @@ -106,7 +106,7 @@ }, jest_cookie_download(needCookie: boolean){ uni.downloadFile({ - url: "http://request.dcloud.net.cn/api/http/header/download", + url: "https://request.dcloud.net.cn/api/http/header/download", success: () => { this.jest_result = needCookie ? true : false; }, diff --git a/pages/API/get-system-setting/get-system-setting.test.js b/pages/API/get-system-setting/get-system-setting.test.js index 851dd0764f3c772cee6bdc2af1e44a4469b82f84..779c2a5edc19c0f2510d4c20f56f44db1129845d 100644 --- a/pages/API/get-system-setting/get-system-setting.test.js +++ b/pages/API/get-system-setting/get-system-setting.test.js @@ -1,6 +1,12 @@ const PAGE_PATH = '/pages/API/get-system-setting/get-system-setting' -describe('ExtApi-GetSystemSetting', () => { +describe('ExtApi-GetSystemSetting', () => { + if (process.env.uniTestPlatformInfo.indexOf('web') > -1) { + it('web', () => { + expect(1).toBe(1) + }) + return + } let page; let res; diff --git a/pages/API/request/request.uvue b/pages/API/request/request.uvue index 33489f39b1e8b95251cb357fd1ba2183f0649065..3d3c80b7f267e34030d2a45624e58fb7a964820d 100644 --- a/pages/API/request/request.uvue +++ b/pages/API/request/request.uvue @@ -87,7 +87,7 @@ title: 'request', res: '', task: null as RequestTask | null, - host: "http://request.dcloud.net.cn", + host: "https://request.dcloud.net.cn", url: "/api/http/method/get", method: "GET" as RequestMethod | null, data: null as any | null, @@ -287,4 +287,4 @@ }, } } - + diff --git a/pages/API/upload-file/upload-file.uvue b/pages/API/upload-file/upload-file.uvue index 7cd45b4f942f69eef7a91c1e3e0d7e20fa3699b4..1a59f61db2673a77d12adcaa0806824a79fd4fff 100644 --- a/pages/API/upload-file/upload-file.uvue +++ b/pages/API/upload-file/upload-file.uvue @@ -97,7 +97,7 @@ }, jest_set_cookie() { uni.request({ - url: "http://request.dcloud.net.cn/api/http/header/setCookie", + url: "https://request.dcloud.net.cn/api/http/header/setCookie", method: "GET", timeout: 6000, sslVerify: false, @@ -114,7 +114,7 @@ jest_delete_cookie() { uni.request({ - url: "http://request.dcloud.net.cn/api/http/header/deleteCookie", + url: "https://request.dcloud.net.cn/api/http/header/deleteCookie", method: "GET", timeout: 6000, sslVerify: false, @@ -131,7 +131,7 @@ jest_cookie_upload(needCookie : boolean) { const imageSrc = "/static/uni.png"; this.task = uni.uploadFile({ - url: 'http://request.dcloud.net.cn/api/http/header/upload', + url: 'https://request.dcloud.net.cn/api/http/header/upload', filePath: imageSrc, name: 'file', success: (res : UploadFileSuccess) => { @@ -196,4 +196,4 @@ font-size: 19px; color: #808080; } - + diff --git a/pages/component/navigator/navigator.test.js b/pages/component/navigator/navigator.test.js index 3263e687f19389cb51a79a91d352e1437fb2026e..6e68aba01a64aec7fe0ed5d550e442e2b1d9054a 100644 --- a/pages/component/navigator/navigator.test.js +++ b/pages/component/navigator/navigator.test.js @@ -4,7 +4,13 @@ const PAGE_PATH_REDIRECT = '/pages/component/navigator/redirect' describe('navigator', () => { let page - beforeAll(async () => {}) + beforeAll(async () => { + if(process.env.uniTestPlatformInfo.startsWith('web')) { + // 由于开发期间跳转页面需要编译,web端先跳转一次 + await program.reLaunch(PAGE_PATH_NAVIGATE) + await program.reLaunch(PAGE_PATH_REDIRECT) + } + }) it('navigate', async () => { page = await program.reLaunch(PAGE_PATH) await page.waitFor(500)