Files
bruno/packages/bruno-tests/collection/scripting/api/req/getHost.bru
Pooja 91959ca942 feat: js api supports get path params (#5235) (#6764)
* feat: add URL helper methods to req API (getHost, getPath, getQueryString)

* fix
2026-01-21 18:13:40 +05:30

24 lines
302 B
Plaintext

meta {
name: getHost
type: http
seq: 1
}
get {
url: {{host}}/ping
body: none
auth: none
}
assert {
res.status: eq 200
res.body: eq pong
}
tests {
test("req.getHost()", function() {
const host = req.getHost();
expect(host).to.equal("testbench-sanity.usebruno.com");
});
}