How to do postman api testing in jenkins for a maven spring boot application

Your question may already have an answer on the community forum. Please search for related topics, and then read through the guidelines before creating a new topic.

Here’s an outline with best practices for making your inquiry.

My question:
Hi all, Can someone help me on how to integrate postman api testing in my maven spring boot application via jenkins pipeline?

I’ve already tried:
I am able to get it working by integrating newman.js like mentioned here: https://www.googlecloudcommunity.com/gc/Apigee/Maven-plugin-for-Proxy-deployment-and-running-POSTMAN-test-cases/td-p/8392.

but, this involves having a node_modules directory containing all newman related files which doesn’t seem like a good fix as it adds tons of additional files and increasing app size and few might find this confusing.

I am looking for more on a better clean solution. can someone please share any info on this?

i was able to get this working in a better and minimalistic way by following this: https://learning.postman.com/docs/running-collections/using-newman-cli/integration-with-jenkins/ .

steps:

  1. configure jenkins pipeline to use node
  2. in the build script → install newman package and use newman run <PATH_TO_COLLECTION>
  3. build it :raised_hands:

sharing the screen shot of jenkins job configuration