I'm currently trying to implement few Postman requests with CSV data sources. For instance let assume I have request named "Open as user". In csv file, I have bunch of user credentials with description field that describes user role. I would like to have the ability to change request names to reflect each user roles. For instance, if the request is made as the admin user I would like request name in reports and runner to be "Open as user admin".
In documentation, I've found pm.info.requestName variable but seems it is read-only. I put following in Pre-request Script
pm.info.requestName = "1"; console.log(pm.info.requestName);
but got "Open as user" value instead of assigned "1".
Have anyone tried to do the same trick or know whether it is possible at all?
Aucun commentaire:
Enregistrer un commentaire