Released Selenide 4.5

Blog

Released Selenide 4.5

Per-for-mance!

Good evening!

We released Selenide 4.5! This release is mainly dedicated to performance improvements of Selenide itself.


Speed up method $.setValue()

Selenide had a cool feature… that nobody knew about. Method $.setValue() pretended to be smart so much it could set value not only to text inputs, but also to selects and radio buttons. The idea was that test should remain stable even if developers change element’s type (say, from <select> to <input type="radio">).

But this “smartness” is not for free: during every call to $.setValue() Selenide tried to detect element type, calling several webdriver methods for it. It took tens or hundreds of milliseconds.

Since no one knew about it and did not use it, we decided to abandon this feature for the sake of performance. Now this “smart” behaviour of $.setValue() is disabled by default. If somebody should still need it, the following setting enables it:

-Dselenide.versatileSetValue=true

Thought, there are simpler alternatives:

  • either enable -Dselenide.fastSetValue=true,
  • or use methods $.selectOption() and $.selectRadio().

Thanks to Alexander Popov for the improvement!


Speed up collection methods

Selenide also pretended to be smart when working with collections. For example, the following check:

$$("tr").shouldHave(size(7));

would wait for some time (600 ms by default), even if collection already has 7 elements. Because “probably there will be loaded more elements soon, and test should fail then”.

We also decided to abandon this feature for the sake of performance.

See pull request 549


Added methods $().$x() and $().$$x()

… for searching by XPath inside a web element.

Now you can write like this:

  $("table").$x(".//tr").shouldBe(visible);
  $("table").$$x(".//tr").shouldHave(size(5));

Thanks to Oleksii Cherevatyi for this addition!


Fix support for Opera driver

Thanks to Roman Marinsky for the fix!


Remove unneeded logs

Namely, we removed this message (when Selenide closes a webdriver):

INFO: Close proxy server: 24 -> null

Thanks to Andrew Zakordonets!


Upgraded to org.littleshoot:littleproxy:1.1.2

This applies only for those who uses option Configuration.fileDownload=PROXY.


Upgraded to phantomjsdriver 1.4.3


Added lots of unit-tests for Selenide itself

This is my personal happiness.

Andrew Zakordonets wanted to help the project and wrote a lot of missing unit-tests for Selenide itself. This is cool. Thank you Andrew!


News


We started project selenide-appium

We created a separate project for better Selenide support for Appium framework: github.com/codeborne/selenide-appium

This is only a beginning, but the project actually works. It’s already used in at least one real-life project for testing mobile applications.


We added more projects to Selenide examples

As you probably know, there is a series of mini-projects on github - samples of using Selenide with different tools. Recently we added couple of new samples:

We are working on new samples. Probably it will be Spring Boot, Allure 2 or something else. Feel free to send your own samples!


How can YOU help Selenide?

Dear friend! You can also help Selenide project. You don’t need to be a mature developer with 20 years of experience. No. Good will is the key for success.

For example, we would be very appreciate if you:

  • Review open pull requests and comment if we should merge these changes to Selenide
  • Review open issues and comment:
    • is it weird or reasonable question/feature request
    • is it already done
    • should we implement it
  • Write some missing documentation
  • Write some blog post
  • Write some missing tests for Selenide
  • Add your own examples of using Selenide with other tools on github.com/selenide-examples
  • Find a volunteer designer to helps us with selenide.org (first of all, with mobile version)

Any help is appreciated!

Andrei Solntsev

selenide.org

blog comments powered by Disqus

The project is maintained by