8/5/2023 0 Comments Api testing postman examples![]() ![]() Of course, the idea is far more complex, but I hope you get the point.ĪPI stands for “Application Programming Interface”. API can be compared to the walkie-talkie that enables two-way communication. Once he knows the answer, he presses a button and sends the weather information back to you. He hears your voice and checks whether it’s raining. You press that button, your voice reaches him, and you ask him if it’s raining outside. Imagine you have a walkie-talkie, and your friend is on the other end. In today’s article, we will focus on API Testing with an emphasis on the REST API and Postman. There are a lot of different combinations with various technologies and tools. What is more, they are the responsibility of a developer, not a QA Tester.Īfter the tests are conducted by a developer, it’s time for the QA team to test the functionality of an application’s interfaces. Unit Tests and Integration Tests are great to have, but they aren’t enough to test every aspect of the application. Hence, the Quality Assurance team must ensure that the application works the way it is expected to. Pm.Software development is facing tremendous growth – applications are increasingly in demand, releases are more frequent, and its quality must be maintained at an acceptable level. Let’s write a bit more complex test, with the help of a snippet!įor this, we first delete our test code and then click on a snippet on the right side of the text area. These code-snippets also exist for Pre-requests Scripts they can be used to dynamically generate parts of our requests, like headers or parameters. Right beside the text area, we can find code-snippets and a link to the scripts’ documentation of Postman. If we export it later, it can be found as a string inside our collection JSON. When we click Save, our test is saved besides our request inside our collection. ![]() We can see the result of this test after we clicked Send we just have to scroll down under the text area, we used to enter the test. In this test, we simply check if the response has a 200 status. When we click Send at the top right, the code is executed after Postman has received a response. Let’s add a test script by selecting the Test tab and pasting the following code into the text area: If we select our request, we can see Pre-requests Script and Test tabs below the text field where we entered our target URL.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |