18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

how to test if a element is hidden

sumeetsumeet Members
edited April 2009 in Sahi - Open Source
is there a way to find out if the hidden field is visible or not, if i use _assertExists it fails as the rendered html will have that element in it, but with ajax it hides or shows the field when a particular value is selected from the dropdown.

I want to test if the field is visible or not, comparing the className solves this issue. But is there another way to verify if it is visible or not?

Comments

  • Hi,

    try _assertVisible().

    regards,
    Pankaj.
  • sumeetsumeet Members
    edited April 2009
    we don't have that function provided by sahi, but thats a good idea.

    Narayan - can you make _assertVisible() available
  • narayannarayan Administrators
    I will add. Meanwhile you can use _assert(_isVisible(element));
  • sumeetsumeet Members
    thanks that works
Sign In or Register to comment.