Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » RCP Testing Tool » Wait for a job to finish before proceeding
icon5.gif  Wait for a job to finish before proceeding [message #1625696] Fri, 20 February 2015 15:21 Go to next message
Chris Champion is currently offline Chris ChampionFriend
Messages: 49
Registered: February 2014
Member
Hello,
Are there different options for making RCPTT wait for a job to finish before cancelling a test job/timing out?

One of my test cases either fails after several minutes due to a timeout or, when part of a test suite, is marked as "succeeded" before finishing and all consequent test cases in the suite are marked as failed.

Report:
Test case *01 Create new Database - Create a new database* time: 13 m 25 s
Result: CANCEL, message: Execution is canceled by timeout: 300000
Result: CANCEL, message: Execution is canceled by timeout: 300000

Thank you,
Chris
Re: Wait for a job to finish before proceeding [message #1630566 is a reply to message #1625696] Mon, 23 February 2015 09:04 Go to previous messageGo to next message
Chris Champion is currently offline Chris ChampionFriend
Messages: 49
Registered: February 2014
Member
As far as I can tell, there are several ways to approach this:
1) In the preferences?
2) With a "wait for job creation window to close" script?
3) Some other kind of built-in functionality/ECL script for this?
Re: Wait for a job to finish before proceeding [message #1632496 is a reply to message #1630566] Tue, 24 February 2015 10:00 Go to previous messageGo to next message
Olga Yurchuk is currently offline Olga YurchukFriend
Messages: 245
Registered: September 2014
Senior Member

Hello,

Test execution can't be longer than global timeout. Of course, you can increase timeout but we don't recommend it, because it can just hide a possible problem.

It seems your test fails to execute properly because context fail to restore a part of state required for a test to proceed and test hangs forever in a cycle. This is indicated by the test dependency on test suite.

Could you please attach Execution details for a test hangup diagnostic?


Yours sincerely,
Olga.
Re: Wait for a job to finish before proceeding [message #1638827 is a reply to message #1632496] Fri, 27 February 2015 10:08 Go to previous messageGo to next message
Chris Champion is currently offline Chris ChampionFriend
Messages: 49
Registered: February 2014
Member
Hi Olga,
Is there then no way to request the status of a job, e.g. "Running", "Waiting", etc.?

Execution details just says:
Report:
Test case *01 Create new Database - Create a new database* time: 15 m 50 s
Result: CANCEL, message: Execution is canceled by timeout: 300000
Result: CANCEL, message: Execution is canceled by timeout: 300000
--------------Logs BEGIN-------------------
--------------Logs END-------------------

Thank you,
Chris

[Updated on: Fri, 27 February 2015 14:05]

Report message to a moderator

Re: Wait for a job to finish before proceeding [message #1665371 is a reply to message #1638827] Wed, 11 March 2015 07:44 Go to previous messageGo to next message
Olga Yurchuk is currently offline Olga YurchukFriend
Messages: 245
Registered: September 2014
Senior Member

Hello,

There was a fix related to timing out.
It is available in nightly build, you can download it from here.
Could you please try it and let me know if it works fine for you.
If it doesn't, please attach report and execution details of failed test.


Yours sincerely,
Olga.
Re: Wait for a job to finish before proceeding [message #1681953 is a reply to message #1665371] Tue, 17 March 2015 14:31 Go to previous messageGo to next message
Chris Champion is currently offline Chris ChampionFriend
Messages: 49
Registered: February 2014
Member
Hi Olga,

I was able to test with the latest NB 1.5.5.201503042108 and am still getting the error when I run on default settings:
Execution timed out after 300 seconds

I tried adding--set-q7-option -key jobDebugjobTimeout -value 12000000--to the beginning of the test case because I don't want to change the global settings to run these handful of test cases.

Test case script:
set-q7-option -key jobDebugjobTimeout -value 12000000
get-view "AdminView" | get-tree | select ... | get-menu "Delete Database and Datafiles" | click
get-window "Confirm Database Deletion" | get-button OK | click

loop {
	if [windowExists "Deleting Database ..." | eq true] {
		wait 1000
		recur
	}
	
}

get-view Progress | get-button "Remove All Finished Operations" | click
get-view "AdminView" | get-tree | select ... | get-menu "Create Database" | click
with [get-window -class WizardDialog] {
    get-group "Installation Options" | get-button "Create a new database" | click
    get-group "Database Configuration" | get-editbox 
        -after [get-label "Required memory (% of total memory)"] | set-text 10
    get-button Finish | click
}

loop {
	if [windowExists "Creating Database ..." | eq true] {
		wait 1000
		recur
	}
	
}

get-window "Admintool" | get-object | save-screenshot "C:/Users/.../RCPTT/Screenshots/AdminTool_Testplan/Admin_01-InstallNewDB.png"



Attaching report and execution details.

Thank you,
Chris

[Updated on: Tue, 17 March 2015 14:33]

Report message to a moderator

Re: Wait for a job to finish before proceeding [message #1682022 is a reply to message #1681953] Tue, 17 March 2015 15:09 Go to previous messageGo to next message
Chris Champion is currently offline Chris ChampionFriend
Messages: 49
Registered: February 2014
Member
I've tried all of the "set-q7-options" ECL commands but the only way I'm able to run these tests successfully is with loops waiting for a window to close
loop {
	if [windowExists "Creating Database" | eq true] {
		wait 1000
		recur
	}	
}


and extending the Launch timeout (sec) in Preferences.

Is it possible to change the launch timeout only for specific test cases, or for a specific AUT instead of globally?

Thank you,
Chris

[Updated on: Tue, 17 March 2015 15:11]

Report message to a moderator

Re: Wait for a job to finish before proceeding [message #1687047 is a reply to message #1682022] Thu, 19 March 2015 13:21 Go to previous messageGo to next message
Olga Yurchuk is currently offline Olga YurchukFriend
Messages: 245
Registered: September 2014
Senior Member

Hello,

Thank you for additional details.
It will take some time to investigate it.
Why is it critical to raise launch timeout only for this particular test?



Yours sincerely,
Olga.
Re: Wait for a job to finish before proceeding [message #1687135 is a reply to message #1687047] Thu, 19 March 2015 14:11 Go to previous messageGo to next message
Chris Champion is currently offline Chris ChampionFriend
Messages: 49
Registered: February 2014
Member
Hi Olga,

It's for a Test Suite of ca. 30 Test Cases for a specific AUT used for creating and managing databases. Creating or importing a database usually takes 10 minutes or so, therefore if I don't raise the timeout limit the test times out and all consecutive tests in the Test Suite fail because they can't access other menus while a database is being created/imported.

An ECL script to wait for a task to finish before proceeding would be ideal but I don't think there is one?

Best regards,
Chris
Re: Wait for a job to finish before proceeding [message #1689286 is a reply to message #1687135] Mon, 23 March 2015 08:04 Go to previous message
Olga Yurchuk is currently offline Olga YurchukFriend
Messages: 245
Registered: September 2014
Senior Member

Hello,

There is no setting to change execution timeout only for one test case.
If you raise timeout up to 10 minutes it doesn't affect time of execution.
If you have several test cases which are failing with timeout, you can just skip them until you fixed the root cause of timeout.
I may suggest just run this test separately from other test cases in IDE or with runner and different values of testExecTimeout in testOptions


Yours sincerely,
Olga.
Previous Topic:[SOLVED] Executes shell command
Next Topic:[SOLVED] process kill through rcptt
Goto Forum:
  


Current Time: Thu Apr 25 07:19:04 GMT 2024

Powered by FUDForum. Page generated in 0.02979 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top