1
0
mirror of https://github.com/MontFerret/ferret.git synced 2024-12-23 01:24:30 +02:00
ferret/e2e/tests/static/doc/headers/override_default.fql
Tim Voronov 9b762d32ee
Feature/#360 default driver params (#372)
* Added default headers and cookies

* wip

* Added tests

* Added default headers and cookies to HTTP driver

* Removed unused struct prop
2019-09-05 11:49:21 -04:00

20 lines
442 B
Plaintext

LET url = @static + "/api/ts"
LET page = DOCUMENT(url, {
driver: "http_headers",
headers: {
"single_header": "foo"
}
})
LET el = ELEMENT(page, "#headers")
LET actual = JSON_PARSE(el.innerText)
LET expected = {
"Single_header": ["foo"],
"Multi_set_header":["multi_set_header_value"],
}
RETURN EXPECT(expected, {
"Single_header": actual["Single_header"],
"Multi_set_header": actual["Multi_set_header"],
})