Hacker News new | ask | show | jobs
by chickenfries 3244 days ago
Tried it and I have a few questions about how to use it:

Am I supposed to visit the url I want to start from, even after entering the base url? I was expecting it to open a tab with the base url.

How do I take the JSON export and run it with selenium?

We have a bunch of selenium tests at work that are extremely fragile and generated by coding instead of something that records actions like this. It takes a long time to write tests and no one does it as a result. I would love to get to a system where the tests are created like this and saved to a folder where CI can run them.

2 comments

Thanks for testing ;) The documentation is still very basic. I made a quick screencast just now and put it on https://a9t9.com/kantu/web-automation/chrome#video

In Chrome, you first navigate to the page that you want to automate/test, and then start record.

For use with the Firefox Selenium IDE, use the "HTML" export (not JSON). Then, in the Firefox IDE, you can import these macros simply via the "Open" menu.

In my experience, record & playback tools (like Selenium IDE) generate test code that is a lot more fragile than tests written in code from scratch. I suppose if no one knows how to write anti-fragile tests or it takes way too long, then using a tool like this is a step up. But keep in mind that you may be trading one problem (no one wants to write tests) for another (what the hell are these autogenerated tests even doing? this isn't a regression, it's a feature! etc.)
> I suppose if no one knows how to write anti-fragile tests or it takes way too long, then using a tool like this is a step up.

This is kind of the situation I'm in, but I see how you could get yourself in a position where you have no idea what your longer integration tests do because they're generated by Selenium IDE.

Browser integration testing is hard.