Jared Matthews is Software Quality Assurance Engineer at EnergyCAP.

binary-numbers.jpgAs EnergyCAP, Inc. has taken its software products online, Application Programming Interfaces (APIs) have assumed increasing importance in our product development and quality assurance testing. This blog is about EnergyCAP’s API development, and exciting changes in our quality assurance processes that are making our online software versions more robust and useful for our growing client base.

The Importance of APIs

An Application-Programming Interface is a set of programming instructions and standards for accessing a Web-based software application or Web tool. Some software companies release information about their APIs to the general public so that other developers and some clients can customize applications driven by the power of those APIs.

APIs serve as an interface between different software programs and facilitate their interactions, similar to the way a Graphical User Interface (GUI) facilitates interaction between humans and computers. At EnergyCAP, we use APIs to perform almost every online task, from logging in to creating meters, entering readings, approving or voiding bills, populating bill lists, and so on.

As our developers have continued to create new software driven by APIs, we have come to realize and appreciate how crucial and beneficial automated testing of these APIs can be.

Automated API Testing

I’ve been in the software quality assurance (QA) profession ¬¬for more than 6 years. During that time, I’ve read many blogs, attended several software engineering conferences, and interacted with lots of fellow QA peers. If there is a “Holy Grail” in software QA—something that has been consistently coveted by each and every software engineer in every company I’ve worked for, interacted with, or read about—that one thing would be automated testing.

Automated testing, although it is a dream of every quality assurance and development manager, can be difficult and expensive up-front. The cost alone often deters many companies from fully committing to the idea.

However, when automated testing is done right, the benefits far exceed the negatives. Automated testing actually saves time and money in the long run. Although it is a costly investment to write automated tests, once created, those tests can be run over and over again for weeks or months or years at no additional cost. Furthermore, they are faster than manual tests, and can be run unattended in a variety of different configurations, greatly increasing test coverage and accuracy.

EnergyCAP’s Road to Automated Testing

Prior to using automated testing, we would test the APIs by performing an activity via EnergyCAP that would call a particular API and perform an action. If the action was performed as expected, we knew the API was working correctly. If we wanted to test an API without using EnergyCAP, we would have to manually reconstruct the API using an application like Fiddler. This was very time-consuming and inefficient. This frustration began EnergyCAP’s journey into a new world of automated testing.

At the time, we found an open-source application called Postman that was specifically created for testing and debugging APIs. Postman had some key features that made it a great starting point for automating API tests. With Postman, we could arrange API requests in a manner that simulated tasks performed in EnergyCAP. Postman also allowed us to group and organize all of our API tests. It permitted both QA and Development teams to collaborate on creating API test suites. The Postman interface also included a built-in “test sandbox” that allowed us to write tests against each API using a variety of JavaScript libraries. The most useful feature of Postman was the command line runner, which allowed us to programmatically run the tests we created with any test environment and EnergyCAP database.

The final piece of the puzzle for us was to integrate our API test suites with our software ticketing system. Jira is the software we use to plan future development, track software defects and manage test cases and test results. The result of all this development and integration work is that we now have several test automation suites that run daily at specified times. These results are displayed in real time on dashboards and provide instant feedback to our development team. We currently have over 40 API groupings being automatically run each day to simulate hundreds of API requests. And there are thousands of tests being run per API grouping!

In the past, it would have taken our QA team weeks to manually run such a robust suite of software tests. Today, the tests are run in just minutes, whenever and as often they are needed. This provides our development team with invaluable feedback, and our customers with more frequent software releases containing fewer defects, all at a lower cost than would be possible with more inefficient software production processes.

Stuck with inefficient utility bill processes of your own? See what Tucson, AZ did to take their quality assurance to the next level!

Download the Tucson AZ Case Study

About The Author
Jared Matthews is Software Quality Assurance Engineer at EnergyCAP. In his position, he works collaboratively to ensure the robustness of EnergyCAP's online software applications.
READ MORE

Leave A Comment

subscribe to our blog