i’m have a variable saved in common variables
and i wan’t to test is the output in get is same as the variable
but i keep getting undefiled errors
Maybe someone can advice
From the screenshot, i see that you are trying to access the variable value SdrVersionNumber from global variables. Use the below code in tests script.
var body = pm.response.json(); var expectedValue = pm.globals.get("SdrVersionNumber"); pm.expect(body.SdrVersion).to.eql(expectedValue);
Thank you very much! it worked