Book Image

Digital Transformation and Modernization with IBM API Connect

By : Bryon Kataoka, James Brennan, Ashish Aggarwal
Book Image

Digital Transformation and Modernization with IBM API Connect

By: Bryon Kataoka, James Brennan, Ashish Aggarwal

Overview of this book

IBM API Connect enables organizations to drive digital innovation using its scalable and robust API management capabilities across multi-cloud and hybrid environments. With API Connect's security, flexibility, and high performance, you'll be able to meet the needs of your enterprise and clients by extending your API footprint. This book provides a complete roadmap to create, manage, govern, and publish your APIs. You'll start by learning about API Connect components, such as API managers, developer portals, gateways, and analytics subsystems, as well as the management capabilities provided by CLI commands. You’ll then develop APIs using OpenAPI and discover how you can enhance them with logic policies. The book shows you how to modernize SOAP and FHIR REST services as secure APIs with authentication, OAuth2/OpenID, and JWT, and demonstrates how API Connect provides safeguards for GraphQL APIs as well as published APIs that are easy to discover and well documented. As you advance, the book guides you in generating unit tests that supplement DevOps pipelines using Git and Jenkins for improved agility, and concludes with best practices for implementing API governance and customizing API Connect components. By the end of this book, you'll have learned how to transform your business by speeding up the time-to-market of your products and increase the ROI for your enterprise.
Table of Contents (21 chapters)
1
Section 1: Digital Transformation and API Connect
5
Section 2: Agility in Development
15
Section 3: DevOps Pipelines and What's Next

Configuring unit tests

As you develop and change your APIs, you should be unit testing them incrementally with specific unit test cases for the change you have just made or testing the API in general. The API Connect test and monitor tool allows you to quickly generate these unit tests by simply sending a request to the API URL and getting a response. This tool will provide some assertions that you can use as-is, alter, delete, or add to. Let's take a look at how to configure a simple unit test case for an API that you are working on.

Before you start to create your first unit test, you must ensure that you have the test and monitor tool add-on installed. To verify this, log into API Manager. The bottom right tile on the home screen should be labeled Test APIs, as shown in the following screenshot:

Figure 13.1 – Verifying that the test and monitor tool is installed

Once you have verified that you have the test and monitor tool installed and...