1
0
mirror of https://github.com/MontFerret/ferret.git synced 2024-12-21 01:21:34 +02:00
ferret/e2e/tests/static/doc/cookies/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

21 lines
437 B
Plaintext

LET url = @static + "/api/ts"
LET page = DOCUMENT(url, {
driver: "http_cookies"
})
LET el = ELEMENT(page, "#cookies")
LET actual = (
FOR c IN JSON_PARSE(el.innerText)
SORT c.Name
RETURN c
)
LET expected = {
"Single_cookie": "single_cookie_value",
"Multi_set_cookie": "multi_set_cookie_value",
}
RETURN EXPECT(expected, {
"Single_cookie": actual[2].Value,
"Multi_set_cookie": actual[0].Value,
})