Helium (Selenium, 50% easier) now available for Java

265 views
Skip to first unread message

Michael Herrmann

unread,
Apr 8, 2014, 4:41:48 AM4/8/14
to seleniu...@googlegroups.com
Hi everyone,

I'm one of the co-founders of a project called 'Helium'. Helium is a wrapper around Selenium that offers a more high-level API to web automation: Instead of having to identify web elements by HTML ids, CSS selectors or XPaths, it lets you use simple commands such as

    startChrome();
    goTo("gmail.com");
    write("yo...@email.com", into("Email"));
    write("your password", into("Password"));
    click("Sign in");
    click(Button("COMPOSE"));

The result of this is that web automation scripts become 66% shorter, and 75% quicker to write ([1]). At the same time, Helium is a library just like Selenium, and you can freely mix it with any existing Selenium 2 code.

We just released a Java version of Helium, and I thought you might be interested in trying it out.

I should also say that unlike Selenium, Helium is not open source but a commercial product. The reason for this is that we quit our daytime jobs to work on it, and have not yet found a means of income that would allow us to make Helium open source while sustaining its development. Helium might therefore only be of interest to those of you whose companies are willing to invest in tools to save expensive engineering time.

You can experiment with Helium for free by downloading the trial from our home page, http://heliumhq.com. You will find language bindings for Java and Python there. We will gradually be releasing Helium for other languages (C#, JavaScript, Ruby). If you want to be notified when one of these come out, just ping me at michael [dot] herrmann [at] heliumhq [dot] com.

Happy automating!
Michael

[1]: "Automating Gmail’s web interface with Helium and Selenium"

Denis Veselovskiy

unread,
Apr 9, 2014, 5:06:42 AM4/9/14
to seleniu...@googlegroups.com
Dont try to create a wheel.
There are lots of usable frameworks already.

And the most easiest and powerfull now is http://selenide.org/ 

Enjoy!

BR
Denis


вторник, 8 апреля 2014 г., 11:41:48 UTC+3 пользователь Michael Herrmann написал:

Michael Herrmann

unread,
Apr 9, 2014, 8:26:00 AM4/9/14
to seleniu...@googlegroups.com
Hi Denis,

I hadn't seen Selenide yet, it looks nice. But it is not the same as Helium: Selenide requires HTML ids, CSS selectors or XPaths to identify GUI elements. Helium doesn't.

If you really think Selenide is better, I propose the following CHALLENGE: We take turns naming public URLs (eg. gmail.com, google.com, yahoo.com, facebook.com, twitter.com, ...) and steps to be completed there. We then implement the steps in Selenide and Helium, and the shorter version (minus opening the browser and URL, because that's hidden in Selenide) wins. 

I think the example I gave can be rewritten in Selenide as:

    open("/"); // provided Selenide is instructed to use base url www.gmail.com
    $("#Email").setValue("yo...@email.com");
    $("#Password").setValue("your password");
    $("#signIn").click();
    $(By.xpath("//div[@role='button' and text()='COMPOSE']")).click();

I think the Helium version is *much* easier to read. It's also shorter: Without the opening of the URL, Helium takes 122 characters, while Selenide takes 167.

I thus claim:

HELIUM: 1
SELENIDE: 0

Do you accept the challenge? ;-)

Best,
Michael

Jim Evans

unread,
Apr 9, 2014, 8:46:07 AM4/9/14
to seleniu...@googlegroups.com
Okay, it's time to stop this before it gets out of hand. You've both made your announcements that you have WebDriver frameworks. Great. Consider us informed. If you're going to get into a contest about which is "better", take it to your respective blogs. It has no place here, and I will make sure it stops in this forum (which is, after all, moderated).

Solomon Adekunle

unread,
Apr 9, 2014, 8:48:46 AM4/9/14
to seleniu...@googlegroups.com
Hello Mike,
I have gone through your mail and I just want to say welldone for your initiative with your co-founder, at least you guys have added something to the world of web automation testing tool, May God bless and reward you guys.I have not used it but I will try it out but not as for commercial purpose but for my personal use to keep upgrade myself in the world of testing. I want to say thank you once again.
Regards
Sol.

Krishnan Mahadevan

unread,
Apr 9, 2014, 8:57:23 AM4/9/14
to seleniu...@googlegroups.com
I completely second Jim Evans on that.

Please refrain from using this forum as a stage for contest!

- Krishnan M
iSent.iPad.

> On 09-Apr-2014, at 18:16, Jim Evans <james.h....@gmail.com> wrote:
>
> Okay, it's time to stop this before it gets out of hand. You've both made your announcements that you have WebDriver frameworks. Great. Consider us informed. If you're going to get into a contest about which is "better", take it to your respective blogs. It has no place here, and I will make sure it stops in this forum (which is, after all, moderated).
>
> --
> You received this message because you are subscribed to the Google Groups "Selenium Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
> To post to this group, send email to seleniu...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/7aed180c-fcd5-4066-8368-4ec7ec360097%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

DongXiang

unread,
Apr 9, 2014, 9:08:21 AM4/9/14
to seleniu...@googlegroups.com
HI Machael,

I am sorry I did read a lot about Helium. but i had a question about following codes:

write("your password", into("Password"));

I checked gmial sign in html. the password html looks like below:

<input id="Passwd" name="Passwd" type="password" placeholder="Password">

I am curious how your codes can work? I think into("Password") must be the key to find the element.

from the html. the id or name for the element is not "password", can you tell me how do you locate this element in Helium? check all known way in selenium like By.id, By.xpath and others one by one or you have some special implementation to do it? if one by one, I guess there must have some time waste to locate the target element.

Best Regards,
--david




Date: Wed, 9 Apr 2014 05:26:00 -0700
From: michael....@heliumhq.com
To: seleniu...@googlegroups.com
Subject: [selenium-users] Re: Helium (Selenium, 50% easier) now available for Java
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.

Wojtek R

unread,
Apr 9, 2014, 9:36:36 AM4/9/14
to seleniu...@googlegroups.com
i think that You can use 'for' attribute assigned to the label
try this xpath:

//input[@id=//label[text()='Password']/@for]

personaly i dont think that it's good approach
try run this skript with other language and localization config

Brian Kitchener

unread,
Apr 9, 2014, 9:54:39 AM4/9/14
to seleniu...@googlegroups.com
It seems like both Selenide and Helium take the WebDriver API and convert it into something that looks more like Selenium 1.  The whole purpose of the WebDriver API is to allow you to find WebElements separately from when you perform actions on them.  This allows us to perform multiple actions on the same element without having to perform the find again.  In addition, obfuscating the locators makes building tests easier, but will cause problems when used on sites that aren't built extremely cleanly.  Supposing there are two fields with "Password" in their attributes.  I will end up having to use XPath or CSS to distinguish between them.  

That being said, I always like to see new frameworks, good job on this!  If you're interested, take a look at the Golem framework, which is much more object oriented API and allows for more code reuse.  

Michael Herrmann

unread,
Apr 9, 2014, 10:13:42 AM4/9/14
to seleniu...@googlegroups.com
Hi everyone,

I will try to keep it short and put my replies in this one mail to honor Jim Evans' request.

Jim, your comment made me understand that this is not a good place for a contest. I didn't think about this before posting. I'm sorry. I won't mention it again.

Dennis, if you're still up for the challenge/game, please get in touch at michael[dot]herrmann[ a t ]heliumhq[dot]com.

Sol, thank you for the very nice words and valuing our contribution. If you have any questions about Helium or want to get in touch, please don't hesitate to do so at my email above.

Krishnan, apologies. We won't bother you with this here.

David, you're right, we do have a special implementation, and it's 10-30% slower. What you gain in return is that scripts are 66% shorter and a lot easier to read&write. See http://heliumhq.com/pdfs/AutomatingGmailWithHelium.pdf for the source of these numbers.

My apologies again for anyone I might have annoyed by suggesting to hold the contest here. I was excited by the idea and didn't think about the ramifications. I won't do it again. 

Regards,
Michael
Reply all
Reply to author
Forward
0 new messages