Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

I am new to Selenium IDE. I want to do validations for checkbox. I have tried the below code

<tr>
<td>mouseOver</td>
<td>name=viewIndex</td>
<td>356</td>

 <tr>
    <td>click</td>
    <td>name=viewIndex</td>
    <td>356</td>
</tr>

It is executing the result as

[info] Executing: |mouseOver | name=viewIndex | 356 |

But there is no progress in my webpage.

share|improve this question
    
What is meant by "validations for checkbox"? Are you trying to see if a checkbox is present on the page, or are you trying to click on the checkbox itself? –  SheyMouse Oct 24 '13 at 13:48
    
when i click at a check box, my selenium must say or should do select the particular check box i did –  Emmanuel Angelo.R Oct 25 '13 at 4:42
add comment

2 Answers

I would use Selenium Builder instead of Selenium IDE. If your script was exported as Java, then you just do this:

WebElement checkbox = driver.findElement( By,id('the_id' ) );
if ( checkbox.isSelected() ) {
  System.out.println("Checkbox was already selected: " + checkbox.toString() );
} else {
   checkbox.click();
}

I use this project template to run my Builder scripts.

share|improve this answer
    
Thanks for giving an introduction into selenium builder –  Emmanuel Angelo.R Feb 14 at 4:24
add comment
up vote 0 down vote accepted

I just used check in command for checking the particular value and uncheck for unchecking the value for it.

As my code goes below

<tr>
<td>check</td>
<td>loggerCheck</td>
<td></td>

<tr>
    <td>uncheck</td>
    <td>loggerCheck</td>
    <td></td>
</tr>
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.