postman-test-helpers
v4.0.0
Published
Reusable functions for Postman test automation.
Readme
Postman Test Helpers
Reusable functions for Postman test automation.
Installation
In Postman scripts, use:
const helpers = pm.require('npm:postman-test-helpers');Usage
const helpers = pm.require('npm:postman-test-helpers');
const current_step_index = eval(pm.collectionVariables.get("current_step_index"));
const config = helpers.getCurrentConfig(current_step_index, "test_sessions_inline_actions_steps");
helpers.goToNextStep(current_step_index, config);Functions
getCurrentConfig(index, arrayName)- Get config for current stepgoToNextStep(index, config)- Move to next requestsetVariablesFromConfig(config, variableNames)- Set variables from configsetJsonVariables(config, variableNames)- Set JSON variables from config
