GuiTest - scraping the content of dropdown in Jave app?

Discussion in 'Perl Misc' started by Woland99, Oct 8, 2011.

  1. Woland99

    Woland99 Guest

    Hi - I am trying to use Perl to run a simple test scrip on Java app. I
    need to run same testcase for ALL the items on one of the dropdown
    controls. Problem is - content of that control ie. item on that
    dropdown list may change from build to build and there is a LOT of
    them 50+ so not feasible to simply copy them by hand.
    Is there any way to use Perl to extract content of such control?
    I tried GuiTest module - it does ok job in controlling the pp although
    it does not seem to see any child windows on it - just the main one -
    of class SunAwtFrame - I can do SenKeys and it is sufficient to run
    the test but I really need to enumerate results by the content of that
    control. Perhaps there is another tool better suited for the task of
    running Java app?

    TIA for any pointers/references/hel,

    JT
     
    Woland99, Oct 8, 2011
    #1
    1. Advertisements

  2. Woland99

    Woland99 Guest

    Thanks for reply Ben,
    As I said WinSpy sees that Java app as single object of class
    SunAwtFrame.

    Technically yes I could get access to Java source code but that app
    is
    written and maintained by entirely diff group in our organization and
    that would require going through million hoops.

    Yes Win32:GuiTest and I can't seem to get handle to combo box - but
    thanks
    for that pointer.

    JT
     
    Woland99, Oct 8, 2011
    #2
    1. Advertisements

  3. Woland99

    Woland99 Guest

    Hmmm - it will be super ugly but I think I can grab a shot of the app
    win every time I make a selection, crop it and run it thru some
    freebie OCR (all using GuiTest) - it will be slow but will suffice
    until I can connect with that app team and persuade them to change
    their code. Thanks, Ben.
     
    Woland99, Oct 9, 2011
    #3
  4. Woland99

    Stevoisiak

    Joined:
    Oct 2, 2017
    Messages:
    1
    Likes Received:
    0
    > Is the Java app using AWT or Swing? (I presume you're not talking about
    > something web-based, which would be much easier to test.) If it's Swing
    > you probably can't get at the contents at all: Swing does its own
    > drawing, so as far as the OS knows there's nothing there but coloured
    > pixels. If it's AWT then I thought AWT used real OS controls, but ICBW.

    I'm working with Kronos Workforce Central 6.3. I can't tell which it uses.

    How can we identify whether a Java app is using AWT or Swing?
     
    Stevoisiak, Oct 2, 2017
    #4
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.