Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6151455
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T19:46:16+00:00 2026-05-23T19:46:16+00:00

I am testing a site written in Javascript, by writing (very simple) Java tests

  • 0

I am testing a site written in Javascript, by writing (very simple) Java tests in Eclipse and running them as JUnit tests.

As I am almost completely new to Java, I am encountering problems all over the place. For example: on the webpage, there are a few buttons that have alt-text that appears if the mouse is hovered over the buttons for half a second.

I use Selenium IDE 1.0.10 to get the scLocator IDs, but it does not pick up the ID for the alt-text pop-up. If, in the Selenium IDE, I use "mouseOver" or "mouseOverAndWait", nothing happens. The test does not fail, as the element is present, yet the alt-text does not appear.

What java command can I use for mouseOver? I guess I can use "assertScElementPresent('', 10*SECONDS);" once I find the element, but what command can I use in java to simulate a mouse hover over a button?

I hope the question is clear and makes sense.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T19:46:16+00:00Added an answer on May 23, 2026 at 7:46 pm

    Did you mean to say “title” attribute, instead of alternate text? Hovering over a button displays the title. The img alt attribute (alt attribute) is used if the browser cannot find the image resource–it then displays the alt text. I don’t know what your ids are, so I’m assuming you are using a LinkButton control with an Image control inside of it given your details. I have two solutions below. If you’re using this for using the variable later, then use the first answer by using an Accessor and an Action. If you are just validating the UI, then use the second answer, which would be an Assert (validation command) alone.

    ASP.NET code:

    <asp:LinkButton ID=”LinkButton1″ runat=”server”>
    <asp:Image ID=”Image1″ runat=”server” AlternateText=”img text” ToolTip=”button” ImageUrl=”http://www.google.com/intl/en_com/images/srpr/logo1w.png” />
    </asp:LinkButton>

    Rendered HTML code:

    <a id=”LinkButton1″ href=”javascript:__doPostBack('LinkButton1','')”><img id=”Image1″ title=”button” src=”http://www.google.com/intl/en_com/images/srpr/logo1w.png” alt=”img text” /></a>
    <input name=”TextBox1″ type=”text” id=”TextBox1″ />

    #1 (Accessor & Action):

    Command: storeText
    Target: xpath=//img[@id=’Image1′]/@title
    Value: var_img_title

    Command: type
    Target: TextBox1
    Value: ${var_img_title}

    #2 (Assert):

    Command: assertAttribute
    Target: xpath=//img[@id=’Image1′]/@title
    Value: button

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm testing the basics for exchanging rest messages between a asp.net mvc site and
We deployed a live, fresh, swanky site using preview 3 including rigorous stress testing.
After learning about TDD and unit testing, I'm really looking to write tests when
I'm trying to understand the Activity Testing tutorial on the Android site. One of
The web site that we're writing needs to be Accessible. The trouble is, while
Testing: return request.getCookies() == null; is not an appropriate way test. Is there another
Unit testing and ASP.NET web applications are an ambiguous point in my group. More
Unit testing is, roughly speaking, testing bits of your code in isolation with test
For testing purposes I have to generate a file of a certain size (to
Unit testing sounds great to me, but I'm not sure I should spend any

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.