pm.execution.skipRequest() doesn't update Skipped Test count

I have several test collections, which include requests with Pre-request scripts that may call pm.execution.skipRequest(). This works just as I hoped, so thank you for this handy function introduced last year.

I was surprised though to realize that calling this does not increment the “Skiped Test” count in either the Runner or in Newman. Was this an intentional decision, or an oversight?

I don’t see the Skipped Test count increment when running Newman or the folder collection runner in Postman Version 11.9.2 for MacOS.

I would like an easy way (other than grepping for console.log output) to see if tests have been skipped. Incrementing the existing Skipped Test count seems like a useful way to do this. If there are circumstances where it DOESN’T make sense to increment the Skipped Test count, perhaps a parameter could be added so that the developer could choose the behavior that they want?

Thanks for your consideration!
–jp

These are different things.

One is completely skipping a request, that could or could not have tests in it and the other is using the pm.test.skip() option to explicitly skip a test.

Thanks for the reply Danny. That makes sense.

I’d still like a way to check my output to see if there were any skipped Requests. Is there a way to detect that after a run?

Cheers,
–jp

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.