anyproxy/test/data/headers.js
砚然 e489e188f4 Add test cases for the proxy, and do some tiny fixes.
the fixes are:
1. add "content-type" in headers for when dealing with localresponse
2. make a more accurate tip for throttle rate when lower than 1
3. make the crtMgr funcionality a more independent one
4. uppercase the request header before sending it out

update the tip
2016-08-31 10:41:29 +08:00

29 lines
969 B
JavaScript

/*
* 用于放置所有header信息的测试数据
*
*/
// Get 和 Post共有的header信息
/*eslint max-len: ["off"]*/
const CommonRequestHeader = {
Accept: 'application/json;charset=utf-8,text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8',
'Accept-Charset': 'utf-8',
'Accept-Encoding': 'gzip, deflate',
'Accept-Language': 'zh-CN',
'Accept-Datetime': 'Thu, 31 May 2007 20:35:00 GMT',
'Authorization': 'Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==',
'Cache-Control': 'no-cache',
'Connection': 'keep-alive',
'Cookie': 'testCookie1=cookie1; testCookie2=cookie2',
'Content-Type': 'application/x-www-form-urlencoded',
'Date': 'Tue, 15 Nov 1994 08:12:31 GMT',
'Origin': 'http://localhost',
'Pragma': 'no-cache',
'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36'
};
module.exports = {
CommonRequestHeader
};