August 17

Is Selenium API Testing Possible?

Selenium API Testing

Selenium automates browsers. It allows software developers to interact with web browsers in order to automatically test their applications. But can you use Selenium testing for API testing? Is Selenium API testing even possible?

Read on to learn:

  • API testing
  • Incorporating API testing with Selenium testing functional tests
  • If Selenium is great for API Testing

INDEX
APIs and Automated Testing
How do I incorporate API testing with my Selenium Testing functional tests
Selenium is not a tool for API testing
For more API Testing Awesomeness

Get FREE Training

APIs and Automated Testing

One question that came up during this year's Automation Guild session on Testing RESTful APIs with Rest-Assured with Bas Dijkstra was whether you can use Selenium for API testing.

This is actually a question that, surprisingly, I get asked all the time. But I liked Bas's answer in our TestTalks interview and during the Automation Guild Conference so much that I decided to share it with you.

How Do I Incorporate API Testing With My Selenium Testing Functional Tests

As I mentioned, whenever I talk about API testing, one question that probably comes to mind to most testers is, can I use Selenium for API testing, and if not, how do I incorporate API testing with my functional tests?

Bas pointed out that he actually wrote a blog post on this fairly recently on what Selenium is and what it is not. Because he also sees this question quite often, surprisingly often on media such as LinkedIn or specialized test automation forums and Twitter even.

For anybody who knows a little about Selenium webdriver that it's a … I'm not even calling it a test tool per se because it's a browser automation tool that simulates the interaction of a user with a browser. It does not simulate the interaction of a user of a system we make.

Selenium Is Not a Tool for API Testing

That should make it pretty clear that Selenium is not a tool for API testing.

Well, of course, if you have a user interface-based or custom framework which is built around the Selenium web browser, you could easily extend that framework to include API testing, but you need a different tool or library for doing that.

One of those libraries that Bas uses is Rest-assured. The Serenity framework also has nice integration for Selenium Testing and Rest-Assured, which you should check out.

For More API Testing Awesomeness

For those of you that missed Bas and all the other awesome speakers at this year's Automation Guild Conference –no worries! Due to demand, I decided to keep registration open.

So you can still get all pre-recorded sessions and recorded Q&A now!

Join Now at No Cost!

About the author 

joecolantonio Colantonio

Hi. I’m Joe Colantonio, founder of Test Guild – I'm the host of the longest-running podcast on automation testing, the Test Guild Automation podcast est. in 2014 (formerly TestTalks), and the creator of AutomationGuild (est. 2017), the premium, annual online event for test automation engineers.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Want to Reach Your Ideal Audience?

The Test Guild community is made up of a highly engaged, growth-oriented, and ambitious audience of 33k+ software testing professionals.

If you're in the DevOps automation/software testing space and want to offer real-world value/solution that can improve the skills or solve a problem for the Guild community, I'd love to hear from you.