Given a private instance MY-WPT-SERVER with apiKey MY-API-KEY and a plaintext batch-tests.txt file containing:
test https://example.com -k MY-API-KEY -l us-east-1-linux:Chrome.FIOS -L MY-TEST-LABEL-DESKTOP -r 3 -v
test https://example.com -k MY-API-KEY -l us-east-1-linux:Chrome.FIOS -L MY-TEST-LABEL-MOBILE -r 3 -v -W --device Nexus7
I'd expect running:
webpagetest batch batch-tests.txt -s MY-WPT-SERVER
to return a JSON array with 2 objects, e.g.
[
{
"statusCode": 200,
"statusText": "Ok",
"data": {
"testId": "210628_T8_1",
"jsonUrl": "MY-WPT-SERVER/jsonResult.php?test=210628_T8_1",
"xmlUrl": "MY-WPT-SERVER/xmlResult/210628_T8_1/",
"userUrl": "MY-WPT-SERVER/result/210628_T8_1/",
"summaryCSV": "MY-WPT-SERVER/result/210628_T8_1/page_data.csv",
"detailCSV": "MY-WPT-SERVER/result/210628_T8_1/requests.csv"
}
},
{
"statusCode": 200,
"statusText": "Ok",
"data": {
"testId": "210628_YQ_2",
"jsonUrl": "MY-WPT-SERVER/jsonResult.php?test=210628_YQ_2",
"xmlUrl": "MY-WPT-SERVER/xmlResult/210628_YQ_2/",
"userUrl": "MY-WPT-SERVER/result/210628_YQ_2/",
"summaryCSV": "MY-WPT-SERVER/result/210628_YQ_2/page_data.csv",
"detailCSV": "MY-WPT-SERVER/result/210628_YQ_2/requests.csv"
}
}
]
but what I get instead is a 200 OK for the 1st test, and a 400 - Invalid location... for the 2nd test
-- even though they use the same location.
[
{
"statusCode": 200,
"statusText": "Ok",
"data": {
"testId": "210628_T8_1",
"jsonUrl": "MY-WPT-SERVER/jsonResult.php?test=210628_T8_1",
"xmlUrl": "MY-WPT-SERVER/xmlResult/210628_T8_1/",
"userUrl": "MY-WPT-SERVER/result/210628_T8_1/",
"summaryCSV": "MY-WPT-SERVER/result/210628_T8_1/page_data.csv",
"detailCSV": "MY-WPT-SERVER/result/210628_T8_1/requests.csv"
}
},
{
"statusCode": 400,
"statusText": "Invalid Location, please try submitting your test request again."
}
]
Reversing the order of the 2 tests in the .txt file results in the same behavior (ie, whichever is listed 1st works, whichever is listed 2nd fails).
So I'm thinking this has to be a bug in the wrapper.
Thanks in advance for taking a look -- and more generally for creating this awesome, useful tool. :)
Given a private instance MY-WPT-SERVER with apiKey MY-API-KEY and a plaintext
batch-tests.txtfile containing:I'd expect running:
webpagetest batch batch-tests.txt -s MY-WPT-SERVERto return a JSON array with 2 objects, e.g.
but what I get instead is a 200 OK for the 1st test, and a 400 - Invalid location... for the 2nd test
-- even though they use the same location.
Reversing the order of the 2 tests in the .txt file results in the same behavior (ie, whichever is listed 1st works, whichever is listed 2nd fails).
So I'm thinking this has to be a bug in the wrapper.
Thanks in advance for taking a look -- and more generally for creating this awesome, useful tool. :)