Check to see if apps are running

Two parts to the same question:

1) Is there any way to check to see if a particular application is running?

2) If I have apps that appear as a pop-up list in the start menu, is there a way to check that each one (of three) is in the list.

I have a login script that executes three separate process: A comand console, a java gui, and an executable application. Before I begin testing my apps, I need to verify that each of the pieces is actually running. How do we do that with Eggplant?


  • EggplantMattEggplantMatt ForumAdmin admin
    The answer to the question "How do I do x in eggPlant?" is almost always, "How would a user do x?" As a user, it sounds like you open the Start menu and look for the 3 separate processes, so that's what your script would do:
    TypeText windowsKey // open the Start menu
    WaitForAll 10, "process1", "process2", "process3"
    This is one approach; if any of the processes aren't found, then the script will just fail. You could also do something like this:
    Typetext windowsKey
    if not imageFound("process1") then
          -- do what is needed to launch process1
    end if
    TypeText windowsKey
    if not imageFound("process2")? // etc.
    The same answer applies to your first question -- how do you as a user determine whether an application is running? There aren't really any shortcuts in eggPlant scripting other than those provided by the OS/application being tested. So you could have eggPlant look for the application in the Start menu or in the Task Bar or if you expect it to be up and running, you can just look for some element of the application's UI.
Sign In or Register to comment.