jQuery in Action, 2nd edition*
The moose likes JSF and the fly likes JSF validations capture using Selenium Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "JSF validations capture using Selenium" Watch "JSF validations capture using Selenium" New topic
Author

JSF validations capture using Selenium

Kavala Naresh
Greenhorn

Joined: Sep 10, 2012
Posts: 3
Dear Ranchers,

I am using selenium webdriver to test my web application being developed using primefaces. I want to capture all validation messages and test results of selenium scripts into a log file.
i.e messages captured into FacesMessage or Primefaces framework related messages being thrown during execution ..etc.
As far as I explored Selenium will not go beyond browser to get the data.

Could somebody please guide, can I achieve this using Selenium or Selenium+TestNG?

Warm Regards,
Naresh
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15964
    
  19

Welcome to the JavaRanch, Kevala!

Selenium is strictly a client-side mechanism. It cannot access webapp internals. Actually, no client-side mechanism should be able to arbitrarily access webapp internals, for obvious security reasons, but selenium has the same restrictions as any other web client.

I am not a big proponent of tests that capture a lot of stuff to logfiles. Ideally, tests should indicate only success/failure, and only the failures should go into details. As projects get bigger, if you log everything, you risk losing important information in the crowd, so to speak.

Selenium tests can be converted into program source code to produce a stand-alone test application.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: JSF validations capture using Selenium
 
Similar Threads
Ant classpath issues
how to capture screenshots of flex application using Selenium?
Selenium RC test with ajax
Testing java applets using selenium with Junit
Selenium test with ajax calll