tbobm/machinery

CI implementation using Postman

Closed this issue · 5 comments

Create a CI workflow to check routes on our services.

A good start would be to look at Postman's Newman CLI tool to run our collection(s).

Howether, due to recent (and future) updates on free-tier team capabilities, looking for Postman alternatives would make sense (thinking about Insomnia and locust to provide the same experience)

I still don't know how we will arrange every request (multiple sub-collections ?), but it would be great to talk with you about implementation.

tbobm commented

@nicolasdecorbez I've started to document the current state of functional testing machinery#functional-test

I'm quite open to any suggestion, but as I've seen your work on newman I think it would be the more simple solution at this current time 🤷‍♂️ follow your heart

We're aiming for a "BestEffort" grade POC, therefore a more robust and long term functional testing tool such as the ones you mentioned could be a great addition for the V2

Funny enough, I've been using Insomnia for a couple of weeks, I'll probably work on the inso test thingy by the end of the year, feel free to refactor my existing work in favour of Inso if you feel like it 🙆‍♂️

@tbobm using newman is surely the simplest way to implement it.

I saw you already used a Postman collection in #14, under postman. I'll work with this sample as basic implementation.

I personally never worked with Insomnia, but it would be very interesting to learn more on inso test, instead of using composed solutions. Thanks m8 !

By starting to work on this part, I remember that I had to warn you about using static file to define postman collection.

It's good for testing few endpoints while setting up the ci, but for bigger project it is way more reliable to generate a link to the collection and or a private key to access it, if it contains sensitive datas.

You can refer to Postman official documentation to see how you can share your collections, or how to work with the Postman API

tbobm commented

Man, that's a lot of information ! Everything has been noted down on my side.

With that in mind, I think we can go with postman/newman for the POC and maybe we'll challenge something a bit more robust and "long term" for the production version ?
Maybe even develop an SDK that will allow to easily create functional testing on our side, who knows.

Are you still up for some work on this part ? I can easily draft some bits of automation if you're more interested in writing the "long term" version of the functional tests, as long as they are easy to write and handle :)

As you can see right above, I'm still up for some work on this part :)

I implemented the "POC version" of the functional tests to the main CI using Postman & Newman. As said into #19, it would be great to open a brand new issue to discuss on the "long term" version, if it fits to your need ;)