X-paramater issue in postman test

MY yaml file from swagger hub contain special parameters according to documentation :

as a part of info object:

description: Test Api
version: "1.0.0"
title: Test API
email: [you@your-company.com](mailto:you@your-company.com)
name: Apache 2.0
url: 'http://www.apache.org/licenses/LICENSE-2.0.html'
#below element
- solution: IRIS
- domain: Clinical
- rdcmLayer: 2

I am unable to wrote test for this paramaeter:

console.log("Start Test");
const jsonData = pm.response.json();
const response = pm.response;

pm.test("Response contain filters/refineers parameters", function() {
console.log("Response contain refiners" , jsonData.info.x-filters);
console.log("Finish Test");

In this line:

console.log("Response contain refiners" , jsonData.info.x-filters);

i receive error: /referenceError: filters is not defined, but they are in JSON response:

"x-filters": [
        "solution": "test"
        "domain": "home"

Hey @Admin2018131210

You would need to access the property like this as it contains the - character:


I’m not really sure what you’re doing in the test though - What are you trying to assert against?