chore: removed collection vars test as cli support is not yet ready

This commit is contained in:
Anoop M D 2024-09-04 11:20:03 +05:30
parent cb395e7649
commit 46017a6c50
2 changed files with 0 additions and 87 deletions

View File

@ -1,39 +0,0 @@
meta {
name: vars asserts
type: http
seq: 5
}
post {
url: {{host}}/api/echo/json
body: json
auth: none
}
body:json {
{
"boolean": false,
"number": 1,
"string": "bruno",
"array": [1, 2, 3, 4, 5],
"object": {
"hello": "bruno"
},
"null": null
}
}
vars:pre-request {
vars_asserts__request_var: vars_asserts__request_var__value
}
assert {
vars_asserts__request_var: eq vars_asserts__request_var__value
vars_asserts__runtime_var: eq vars_asserts__runtime_var__value
vars_asserts__env_var: eq vars_asserts__env_var__value
}
script:pre-request {
bru.setVar('vars_asserts__runtime_var', 'vars_asserts__runtime_var__value');
bru.setEnvVar('vars_asserts__env_var', 'vars_asserts__env_var__value');
}

View File

@ -1,48 +0,0 @@
meta {
name: pre-vars
type: http
seq: 5
}
get {
url: {{host}}/ping
body: none
auth: none
}
headers {
request_pre_var: {{request_pre_var}}
}
vars:pre-request {
request_pre_var: {{folder_pre_var}}
request_pre_var_token: request_pre_var_token_value
request_pre_var_1: request_pre_var_1_value
request_pre_var_2: {{request_pre_var_1}}
}
assert {
collection_pre_var: eq collection_pre_var_value
folder_pre_var: eq folder_pre_var_value
}
tests {
test("collection pre var bru function", function() {
expect(bru.getCollectionVar('collection_pre_var')).to.eql('collection_pre_var_value');
});
test("folder pre var bru function", function() {
expect(bru.getFolderVar('folder_pre_var')).to.eql('folder_pre_var_value');
});
test("request pre var bru function", function() {
expect(bru.getRequestVar('request_pre_var')).to.eql('folder_pre_var_value');
});
test("request pre var self-interpoaltion", function() {
expect(bru.getRequestVar('request_pre_var_2')).to.eql('request_pre_var_1_value');
});
}