SDET Unicorns

Javascript API Automation Tutorial Series

Table of Content

API testing is extremely important to ensure your application’s business logic or the functionality of the APIs are working properly as well as to ensure they are performant and secure.

Some of the advantage.s of doing API testing:

  • Early application access: You can start testing the APIs the moment they are built without having to wait for the UI layer to be ready
  • Test speed: API automation testing is a lot quicker and covers more application ground in less time compared to browser testing
  • Easier to maintain: If you’ve worked on browser tests then you probably are aware of with some of the pain points around flaky tests. With API tests, you don’t have to worry about that as tests are a lot more stable and consistent (most of the times)

There are primarily two ways of performing API testing:

  • Manual: by using tools like Postman or any other API console
  • Automation: programmatically running your API tests using the programming language of your preference

In this tutorial series, we will walk through both the options but mainly focusing on the latter option (Test Automation)

Some of the items we will be covering in this series:

  • Basics
    • What is an API?
    • What is REST API?
    • Different types of API Methods
    • What contains in an API Request?
    • What is API testing and the advantages of API testing
    • What technologies we will be using for API testing
  • Installation / Configuration
  • Write API automation tests with Javascript using Mocha, Chai JS, and SuperTest HTTP Library
  • Scale API automation test framework
    • Learn how hooks work and when to use it
    • Write some negative tests to increase our test coverage
  • Generate fake test data to make tests more dynamic
  • Generate HTML reports using Mochawesome reporter
  • Integrate tests with Jenkins
  • and a lot more…

My Resources

Thrive Suite: The all-in-one WordPress theme I used to create my blog.
Jasper AI: My favorite AI writing tool.
Surfer SEO:  A tool to help you rank your content on the first page of Google.

Write Content Faster


Write blog posts that rank for affiliate terms!

Join our mailing list

Unlock the Secrets to Becoming a SDET Pro in the Industry!

Stay ahead of the curve! Join our mailing list for exclusive insights, tips, and the latest industry updates delivered straight to your inbox

Table of Content

Related Post

Differences Between CI/CD and DevOps

Key Differences Between CI/CD and DevOps

Software development is far from a simple journey that involves merely executing code and launching applications. It often presents challenges, as it’s rare to get everything right from the start. Each time you implement new or frequent code changes, you inadvertently introduce potential issues that can be time-consuming to resolve. This complexity necessitates a structured approach to ensure smooth production.

Read More »

Common Types of Software Bugs

Dealing with bugs is one of the biggest headaches in the software development lifecycle. No matter how carefully someone writes code, it’s impossible to create a software product that works perfectly every time. Skipping detailed testing often causes major issues later on.

Read More »