Product Needs to be RESTARTED scenario

WindowTester allows you to easily create and run unit tests for every GUI they build. It can also be used to generate system level tests.

Moderators: gnebling, Eric Clayberg, Dan Rubel, keertip, Phil Quitslund

Product Needs to be RESTARTED scenario

Postby jayvir » Mon Nov 23, 2009 6:51 am

Hi,

I am struggling to write a test scenario, where my testcase flow, needs to restart the Eclipse. Could you please let me know, how to handle these sort of scenarios?

What exactly I am trying to write a testcase for is....

Help-->Install Nee Software--> Add Install sites --> Install --> After Installation, need to Restart --> Once Restarted verify installation under "window->Preferences", "window->show view".

Is there anyway, I can make WindowTester wait for the Product restart and then continue ahead verifying the facts, once product is restarted???? As of now, windowTester marks test pass and exits and again relaunches the testcase by itself right from beginning of the testcase.

I have found a workaround to make windowtester contuinue from where it has left the job while restarting (by writing a Flag on diskfile and putting if-else check), but then since the main/Parent instance of Eclipse, on which this JUNIT test is executing, is never restarted(I suppose this is the reason), I never get to see those perspective/views from the Window Menu.

I am posting this here thinking that, I can not be the first person who is encountering this scenario.

Thanks
Jayesh
jayvir
 
Posts: 4
Joined: Tue Oct 27, 2009 11:08 pm

Re: Product Needs to be RESTARTED scenario

Postby Phil Quitslund » Mon Nov 23, 2009 11:08 am

There is no way to do this within a WT test. When eclipse is terminated the test runner is terminated and so is the test thread. How are you running your tests? Are you running them in a runtime workspace from within eclipse or from a commandline script?
--
Phil Quitslund
Software Engineer
Google, Inc.
Phil Quitslund
Moderator
 
Posts: 491
Joined: Fri Apr 28, 2006 6:26 am

Re: Product Needs to be RESTARTED scenario

Postby jayvir » Tue Nov 24, 2009 1:17 am

Hi Phil,

I am running it from runtime workspace from within eclipse.

Jayesh
jayvir
 
Posts: 4
Joined: Tue Oct 27, 2009 11:08 pm

Re: Product Needs to be RESTARTED scenario

Postby Phil Quitslund » Tue Nov 24, 2009 8:22 am

A kind of clumsy solution might be to have two test suites that share the same data location. The first clears the workspace and does the install and the second tests the install. It would then be up to you to run the suites one after another. A bit cumbersome but let me know what you think...
--
Phil Quitslund
Software Engineer
Google, Inc.
Phil Quitslund
Moderator
 
Posts: 491
Joined: Fri Apr 28, 2006 6:26 am


Return to Window Tester

Who is online

Users browsing this forum: No registered users and 1 guest