What are some web UI automation frameworks available out there?
I know about this question, but it was asked 3 years ago and things have changed a lot since then. I just wanted to find out if the answers to that question are still relevant or there have been newer and better tools developed since.
I'm asking this again because after doing some googling I've stumbled upon tools such as Geb and Capybara that were not mentioned as an answer in that question.
there have been newer and better tools developed since.
Take a look at the TestCafe testing framework. It runs functional tests in any modern browser and any device. No WebDriver required.
TestCafe is a pure node.js solution.
It can be easily installed (npm install -g testcafe is enough).
Works without plugins for browsers and additional configuration.
Write tests in ES6 and ES7 JS syntax.
Has smart waiting system, so runs async tests fast without extra waiting.
Can be easily integrated to your CI system.
Support for running tests on remote machines, devices, and cloud.
Free and open source.
You can use WATIR with Cucumber. Infact facebook uses watir for its UI automation.
I would definitely stick with Selenium, TestNG (and Selenium Grid for industrialisation).
If you want something at a slightly lower layer, you can also look at HtmlUnit.
IBM Rational Functional Tester (IE and older firefox builds) or QA Wizard.
RFT runs on Java/Eclipse.
https://stackoverflow.com/a/13024991/423955
Sahi (http://sahi.co.in/) should be the best alternative for selenium. One can use java or javascript for the sahi scripts, php and ruby driver is also available (no personal experience with Ruby or php). Very effective with cross browser as well as cross-platform.
Some of the lovable features are: No explicit wait required. For element identification _near, _under, _in etc ApI's are very useful. Logging/Report, feature is inbuilt with Sahi. No Complex configuration required to run the Sahi scripts
Related
I'm curious as to the procedure for writing browser plugins for browsers like Chrome, Safari, and Opera. I'm thinking specifically of Windows here and would prefer working with C++.
Are there any tools or tutorials that detail the process?
Note: I am not referring to extensions or 'addons'. I'm referring to a plugin similar to how Flash and Adobe Reader have plugins to handle specific content-types.
As others point out, plugins for those browser are written using the NPAPI.
Note: Both Firefox and Chrome will default most plugins to click-to-play soon, with Chrome planning to phase out NPAPI entirely. NPAPI for new projects is discouraged at this point.
Resources for getting started with NPAPI:
MDC plugin section
three part NPAPI tutorial
memory management in NPAPI
npsimple - the "Hello World" of NPAPI plugins
npapi-sdk - the source for the canonical NPAPI headers
Mozillas test plugin - good for looking up specific NPAPI use cases
The NPAPI itself is however relatively low-level, but there are tools and frameworks that can help you with it:
FireBreath - cross-browser, cross-platform frame-work for plugins
Nixysa - generate glue-code for NPAPI plugins
JUCE - application framework also providing support for plugins
QtBrowserPlugin - Qt based browser plugin framework
I investigated some frameworks listed by Georg, here is what I get:
FireBreath. I think it is almost the best one available. You can create a cross platform browser plugin with FireBreath in a few days. I did find some cons: It does not support utf-8 characters on Windows. For example: if there are Chinese characters in a file name, you cannot read the content of that file. I believe that boost/locale can resolve this issue. But FireBreath does not contain boost/locale. Yes you can use external boost, but I spent several days configuring and tweaking and still cannot get it compiling on Windows. The author uses cmake to orgnize code and sub-projects. And he created a lot of bat or shell scripts and cmake macros, it is very hard to understand and configure. In short, if you want something that FireBreath currently does not provide, you will have a bad luck, it is very hard to add new features.
Nixysa. I don't think that it is being actively developed. Documentation is poor. And from the comments of the wiki page: https://code.google.com/p/nixysa/wiki/HelloWorldWalkThru We can know that users could not get help at all and were having trouble get it running on Windows
JUCE. It is not specially for creating browser plugins. It does NOT support Linux. The author thinks that NPAPI is going to die so he has no plan to support Linux or add new features.
QtBrowserPlugin. You can not find it in documentation later than QT 4.5. In another word, it is not maintained(and removed from Qt 5.0)
I will update this answer once I find more.
Update: Chrome dropped NPAPI support. I think in the future it becomes harder and harder to write plugins in C++ because lacks of support from browsers.
Browsers like Netscape-based browsers, Chrome, Safari and Opera uses NPAPI plugin system, you can learn how to write NPAPI plugins in https://developer.mozilla.org/en/Plugins and http://code.google.com/chrome/extensions/npapi.html
If you know Qt then they have got some classes that makes it easier to implement browser plug-ins
I'm wondering if it's possible to script certain actions of Eclipse itself. I'd like to be able to start a server, stop it, etc. Is this possible and if so, how?
Edit: I'd like to be able to do this so I can run certain server commands just through an SSH connection, no physical interaction required. Thanks.
Note that Martin OBERHUBER announced in his blog (April 2012):
I've started a new initiative to get scripting support back home to Eclipse.org and unify the fragmented landscape a bit.
a mailing list dedicated to scripting in Eclipse: eclipse-scripting-dev
an "Eclipse Scripting BoF session at EclipseCon 2012" page lists the first initiatives.
So:
10 years after bug 8519 (keystroke macros recording and playing capability),
9 years after bug 37680 (Add Eclipse automation),
6 years after bug 158716 ([Workbench] Pull Scripting support into platform),
..., that topic might finally evolve.
I think it is not supported OOTB. You can configure external tools which are basically just canned command lines that you can pass workbench variables. You can write scripts externally in Perl, Python or whatever and invoke them as external commands. The output can be captured in a console tab and you configure it to trigger a workspace rebuild and/or refresh.
You would probably want to check: http://www.viplugin.com/scripteclipse.htm
I am using it to run JavaScripts inside Eclipse to automate some tasks.
Eclipse has a headless mode, mainly tailored for headless builds, but you might be able to leverage that for your purposes. You'll probably have to create your own application or plugin to handle what you want, assuming that the features you need aren't GUI dependent. Search Google for "eclipse headless" to get started.
As of June 2014, the latest official scripting initiative seems to be:
EASE
The project is still under incubation.
Regarding the answer from vonC:
Eclipse scripting got really active again in the last view weeks. Currently the development takes place at github: https://github.com/adaussy/EScriptMonkey
We are striving for a dedicated project in the e4 incubator. A first prototype will be available by end of October. Interested parties may visit the "Scripting baby" session at EclipseCon Europe 2013.
I'm building a Spring web app and up until now all of my testing is using a browser.
This involves starting the server, opening a browser window and checking to see if accessing any of the pages causes an error.
This is starting to get repetitive and doesn't seem to be the most efficient way to do this.
Since the Junit jar file is already in my project, could it be used as an alternative to this browser testing and, if so, any tips on how to get started making JUnit simulate the act of opening a browser to access the web app?
Take a look at Selenium. It allows you to script functional tests using JUnit or TestNG and execute them in a browser, automatically.
You can use the HTMLUnit extension to script to drive the web site from JUnit.
I used a while back and worked fine for thi site I was doing then.
see http://htmlunit.sourceforge.net/
I suggest you to try the Robot Framework. This is an open source testing framework developed by engineers in Nokia Siemens Networks.
It is primarily built on python and the Selenium testing libraries. It also includes support for testing Java/J2EE server side code through Jython libraries. I personally use it in my work sometimes, and writing a test case is just as easy as describing an end-to-end flow through the use of Keywords (most of required ones are already inbuilt). You could go ahead and give this a shot if you find Selenium a li'l tough to work with. The Robot framework provides a fairly simple abstraction over raw selenium, coupled with the power to make Java/J2EE server-side calls too.
Regards,
Nagendra U M
I have a desktop application . The functionality is complete, but user interface requires a lot of work. I am looking for UI tools.My current operating system is Windows and application is required to run on both Windows and Linux.
Can you guys recommend any?
The software is customized file management application for a specific client, with future plans of web integration.
Thanks in advance :)
Application Environment
Lang : java,
IDE : Eclipse 3.4,
Target Platforms : Windows Vista-OpenSuse 11
SWT is another option. The advantages are a look-and-feel closer to the native platform, and generally faster execution times. The main disadvantage is that you will have to have different distributions for different target platforms, as SWT depends on platform specific libraries.
With an eye toward the web integration, look at GWT. You write your interface in Java but it gets generated into Javascript and can thus be run in a browser. This may make your deployments easier. On the downside, you lose a bit of the rich client UI, but maybe you don't even need that. It all depends on how complex your UI is.
A word of advice: you mentioned future plans of web integration. Take special care to isolate what logic you can from the UI. Keep the UI as clean as possible, and then you may be able to use the same logic in the web UI either on the client or the server.
If you are just looking for a GUI designer you could check out Netbeans IDE which has a built-in Swing user-interface builder.
Alternatively you could build a front-end in JavaFX. There's not much tooling for FX yet but a new tool was recently previewed at JavaOne 09. Not sure when it's being released.
I've used Qt a few times and find it very good at this sort of thing -
Qt Home Page I'm not sure if it's exactly what you're looking for as your application is complete, however, but it may be worth a look.
Found an excellent fix,
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
SwingUtilities.updateComponentTreeUI(myform);
looks so cool in my vista and suse , its enough for now.
Thanks for everybody for helping out
I would like some suggestions if your project has some java application elements as well as web then is there an option for testing java applications from the outside like we do with the web applications
Your question is not very clear to me. But from what I understand, I feel jMeter could be something that might help.
jMeter can not only test web applications (from outside) but ALSO standalone java applications.
Also, do not dismiss jMeter as a performance testing tool. There are ample features in it that makes it a good enough tool for Functional testing as well.
Do you mean testing desktop applications through the GUI? If so, there are many tools for doing this, both commercial and open source. Some open-source projects to google for:
Window Licker (I am an author of this one)
FEST
Marathon
Abbot
This is called Blackbox testing.
Typically you would write another program that provides inputs to your applications and verifies the output. This is easier for a command line application but for GUI testing you would need to use a framework like others have mentioned.
Another approach is to write a drive that includes the jar files and directly call the public functions and do input/output testing.