Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 347275

Summary: Retry EventHandler does not reset it's retry count
Product: [Technology] Jubula Reporter: mteuber
Component: CoreAssignee: Marvin Mueller <marvin_m>
Status: CLOSED FIXED QA Contact: Oliver Goetz <Oliver.Goetz>
Severity: normal    
Priority: P3 CC: alexandra.schladebeck, Felix.Ziesel, marvin_m, mteuber
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
Test case describing the problem none

Description mteuber CLA 2011-05-26 05:36:37 EDT
Build Identifier: 

In the exercises of the GUIdancer Course there is a task to create a setup test case that deletes all existing categories.

I have created this test case as a check for an empty category tree.
If it is not empty an EventHandler (Error: CheckFailed; Reentry: Retry) is called that selects the first node of the tree and deletes it via the context menu. After deleting the EventHandler checks if no confirmation dialog is shown (this dialog appears if one tries to delete a category with subcategories). If this dialog is shown another EventHandler (Error: CheckFailed; Reentry: Retry), that confirms the dialog, is invoked from this EventHandler.
The second EventHandlers retry count is set to 1 as he only has to confirm the dialog.

If the tree contains more than one category, that has subcategorie, the test execution fails as the retry count of the second EventHandler is exceeded on the first category

As the deletion EventHandler is called multiple times the EventHandler that is used in it should not be the same over all calls but new for every single call.

Reproducible: Always

Steps to Reproduce:
a proper test case is attached
Comment 1 mteuber CLA 2011-05-26 05:37:42 EDT
Created attachment 196648 [details]
Test case describing the problem
Comment 2 Felix Ziesel CLA 2011-07-11 02:39:17 EDT
Another problem can occur if the Event Handler with the retry throws an internal error itself. If the Test Case runs in a loop the second time the event handler will with the retry will not be called even if the Retry count is bigger than one. Therefore a workaround setting up the retry count will not work for this use case.
Comment 3 Alexandra Schladebeck CLA 2012-05-15 06:43:53 EDT
This has also been mentioned in the GUIdancer Bugzilla:
https://bxapps.bredex.de/bugzilla/show_bug.cgi?id=30
Comment 4 Marvin Mueller CLA 2013-04-18 09:48:59 EDT
We are now resetting the retry counter on a successful event handling, or after the max retry count for the test case is reached(and the default handler is executed).

Fixed with changeset: http://git.eclipse.org/c/jubula/org.eclipse.jubula.core.git/commit/?id=19c2c3595161e8f55803a6183f2d12ace7095ae7
Comment 5 Oliver Goetz CLA 2013-04-24 07:37:15 EDT
Closing this ticket (see https://bxapps.bredex.de/bugzilla/show_bug.cgi?id=30)