|
1299 | 1299 | alert('请先输入有效的URL!')
|
1300 | 1300 | return
|
1301 | 1301 | }
|
1302 |
| - if (baseUrl.indexOf('/apijson.cn') >= 0 || baseUrl.indexOf('/39.108.143.172') >= 0) { |
1303 |
| - alert('请把URL改成你自己的!') |
| 1302 | + //开放测试 |
| 1303 | + // if (baseUrl.indexOf('/apijson.cn') >= 0 || baseUrl.indexOf('/39.108.143.172') >= 0) { |
| 1304 | + // alert('请把URL改成你自己的!\n例如 http://localhost:8080') |
| 1305 | + // return |
| 1306 | + // } |
| 1307 | + if (baseUrl.indexOf('/apijson.org') >= 0) { |
| 1308 | + alert('请把URL改成 http://apijson.cn:8080 或 你自己的!\n例如 http://localhost:8080') |
1304 | 1309 | return
|
1305 | 1310 | }
|
1306 | 1311 | const list = App.remotes || []
|
|
1385 | 1390 | downloadTest: function (index, item) {
|
1386 | 1391 | saveTextAs(
|
1387 | 1392 | '# APIJSON自动化回归测试-前\n主页: https://github.com/TommyLemon/APIJSON'
|
1388 |
| - + '\n\n接口: ' + (item.version > 0 ? 'V' + item.version : 'V*') + ' ' + item.name |
1389 |
| - + '\nResponse: \n' + JSON.stringify(JSON.parse(item.response || '{}'), null, ' ') |
1390 |
| - , 'APIJSON自动化回归测试-前.txt' |
| 1393 | + + '\n\n接口名称: \n' + (item.version > 0 ? 'V' + item.version : 'V*') + ' ' + item.name |
| 1394 | + + '\n返回结果: \n' + JSON.stringify(JSON.parse(item.response || '{}'), null, ' ') |
| 1395 | + , '测试:' + item.name + '-前.txt' |
1391 | 1396 | )
|
1392 | 1397 |
|
1393 | 1398 | /**
|
|
1400 | 1405 | var tests = App.tests || {}
|
1401 | 1406 | saveTextAs(
|
1402 | 1407 | '# APIJSON自动化回归测试-后\n主页: https://github.com/TommyLemon/APIJSON'
|
1403 |
| - + '\n\n接口: ' + (item.version > 0 ? 'V' + item.version : 'V*') + ' ' + item.name |
1404 |
| - + '\nResponse: \n' + JSON.stringify(JSON.parse(tests[item.id] || '{}'), null, ' ') |
1405 |
| - , 'APIJSON自动化回归测试-后.txt' |
| 1408 | + + '\n\n接口名称: \n' + (item.version > 0 ? 'V' + item.version : 'V*') + ' ' + item.name |
| 1409 | + + '\n返回结果: \n' + JSON.stringify(JSON.parse(tests[item.id] || '{}'), null, ' ') |
| 1410 | + , '测试:' + item.name + '-后.txt' |
1406 | 1411 | )
|
1407 | 1412 | }, 5000)
|
1408 | 1413 |
|
|
0 commit comments