DEV Community

Cover image for Selenide Tutorial Series
Dilpreet Johal
Dilpreet Johal

Posted on • Edited on

Selenide Tutorial Series

Hello everyone! In this tutorial series, we will talk about Selenide and learn how Selenide makes it extremely easy to write readable and stable UI tests in Java.

What is Selenide?

Selenide is a UI test automation framework in Java. It’s built on top of Selenium Webdriver, what that means is that you can take advantage of all the low-level features of Selenium Webdriver and on top of that Selenide provides you with added features & functionalities. Selenide is built specifically for automated testing unlike Selenium Webdriver.

  • Readable Code: You can write Readable user friendly code that everyone can understand.
  • Stable Tests: Selenide also provides in-built functionality to write stable tests
  • Config: Selenide requires minimal Setup & Configuration to get started, you can start writing tests in under 15 mins
  • Free: Its free and open source just like Selenium Webdriver

Check out this video to learn more about Selenide in detail:


Selenide Features

  • Finding Elements: finding elements with Selenide is really easy, you can just do $ or $$ to find elements and this is exactly how WebdriverIO find elements as well. So you no longer need to do driver.findElement and so on..
  • Smart Waits: Selenide also has smart waits, this is how it makes your tests stable. For each element, it will wait up-to 4 secs to make sure the element is visible and intractable. It also provides various wait methods which you can use such as should be visible, should disappear and so on..
  • Convenient methods: Selenide provides additional convenient methods to make your day-to-day automation easy such as selectRadio, selectOption and many more..
  • Chainable Commands: One of the ways it makes tests readable is through chainable commands, each command can be chained with other instead of having to write it in a separate line each time
  • Additional Locator Strategies: Selenide also provides with more locator strategies. You can findElement bytext, byValue and in few other ways..
  • Automatic Screenshots: It also has inbuilt capability of taking automatic screenshots on test failures without having to do any configuration for it

What we will cover in this series:

  • Setup & Configuration: Start with setting and configuring Selenide on our machine and you will see how easy that would be.
  • Write Tests: Then we are going to write our first test using the TestNG framework and understand the basics of Selenide
  • Selenide API: Then we will move on familiarizing ourselves with Selenide API
    • We will learn how to work with individual and multiple elements and also how to work with input fields
    • We will also cover how to upload files with Selenide and look into various wait commands that Selenide provides
  • Page Object Model: We will take a look at POM as well and notice how easy setting POM is with Selenide
  • Cross Browser Testing: We are also going to look into how to run tests in Chrome & Firefox with Selenide
  • Reporting: And, finally, how to generate beautiful SureFire reports

That’s what I am planning to cover so far in this series. Let me know in the comments below if you would like me to cover any other specific topic. I am really excited to start this series and I hope you guys are as well!


📧 Subscribe to my mailing list to get access to more content like this as well as be part of amazing free giveaways.

👍 You can follow my content here as well -

...

I love coffees! And, if this post helped you out and you would like to support my work, you can do that by clicking on the button below and buying me a cup of coffee -

Buy me a coffee

You can also support me by liking and sharing this content.

Top comments (0)