Bug 1154109 - IE: Tests cannot set a name of elements
Summary: IE: Tests cannot set a name of elements
Keywords:
Status: CLOSED EOL
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: jBPM Designer
Version: 6.1.0
Hardware: Unspecified
OS: Windows
urgent
high
Target Milestone: ER6
: 6.1.0
Assignee: Tihomir Surdilovic
QA Contact: Sona Mala
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-10-17 14:53 UTC by Sona Mala
Modified: 2020-03-27 19:42 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
IE11
Last Closed: 2020-03-27 19:42:30 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Reproducer - maven project using Selenium, Drone, Graphene (2.98 MB, application/zip)
2014-10-17 14:53 UTC, Sona Mala
no flags Details
State of screen from Jenkins build on IE10 (52.38 KB, image/png)
2014-11-07 09:11 UTC, Sona Mala
no flags Details
IE11CannotNameElement6.1.0ER3 (1.08 MB, image/gif)
2015-02-10 13:20 UTC, Jeremy Lindop
no flags Details
IE11CannotNameElementCurrent (1.00 MB, image/gif)
2015-02-10 13:21 UTC, Jeremy Lindop
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1044613 1 None None None 2021-01-20 06:05:38 UTC

Internal Links: 1044613

Description Sona Mala 2014-10-17 14:53:42 UTC
Created attachment 947903 [details]
Reproducer - maven project using Selenium, Drone, Graphene

Description of problem:
This issue is only for automated tests on IE. We use Selenium and its IE driver for testing jBPM Designer on IE browser.

It seems that there is some collision between IE driver and jBPM Designer.

Our problem is that even if the name is successfully entered into input (Mandatory property or property 'Name' in Properties bar) the name of the element is not shown on canvas. (Run attached reproducer)

This is the key functionality of our tests (a naming of elements) and it is broken since 6.0.2 ER3 BPMS.

Our tests work fine for 6.0.2 ER2 BPMS.

Unfortunately, I am not able to build a community project, right now to investigate where the problem is.

Version-Release number of selected component (if applicable):
6.0.2 ER3 until now 6.1.0 DR3

How reproducible:
When IE driver is active.


Steps to Reproduce:
1. Run reproducer with $mvn clean test -Pie
2. Get a results from surefire plugin
3. Test fails

Actual results:
Start node does not contain desired name.

Expected results:
Start node contains desired name

Additional info:
Run this reproducer with firefox on linux ($mvn clean test -Pfirefox). Test is success.

Comment 1 Kris Verlaenen 2014-10-31 00:06:31 UTC
Sona, have you been able to look into this?  Not sure what to do from engineering side as the feature seems to work well in manual testing?

Comment 3 Sona Mala 2014-11-03 13:28:56 UTC
It seems that problem is caused by this commit:
https://github.com/droolsjbpm/jbpm-designer/commit/8a2e7aadf78ad5825c64715de0fc6e5995571e0d

Comment 4 Sona Mala 2014-11-03 14:38:11 UTC
We have changed condition from ActiveXObject to ExtIE and the reproducer has passed.

Comment 5 Tihomir Surdilovic 2014-11-03 14:53:50 UTC
Changing that is not really a fix because it breaks detection of IE11 which we are specifically targeting in that IF statement. 

Can you tell if it is the code in the IF statement which breaks the tests (causes JS error or something)? IF that is the case we can just put try/catch around it so your tests can still run and it should also run fine in browsers as well.

Comment 6 Sona Mala 2014-11-05 08:27:56 UTC
Hi Tiho,
it seems that the changing of the condition allows to execute the body of IF statement. Unfortunately, the body does not throw any exception.

IF condition is correct. It detects IE10 and IE11.

There is another piece of information. I have tried the reproducer with IE10 and IE11 with the same instance of designer and same version of IEdriver. The reproducer succeeded with IE 10 and it failed with IE11.

So this is IE11 specified problem.

I cannot try IE9 because Designer cannot be opened there.


Please, do you have any idea where the problem is?

Comment 7 Sona Mala 2014-11-07 09:11:10 UTC
Created attachment 954836 [details]
State of screen from Jenkins build on IE10

Comment 8 Jiri Locker 2014-11-28 17:47:43 UTC
I have done some investigation and I am convinced that the problem (failure to set node name illustrated by attachment 954836 [details]) is caused by a feature of IE driver called persistent hovering:

"Persistent hovering is achieved by continuously firing mouse over events at the last location the mouse cursor has been moved to."

My observation was that almost any interaction (draging nodes over canvas, node renaming) was interrupted by the canvas refresh addressing IE renderring issue (bug 1044613).

After disabling IE driver's persistent hovering the test started to succeeed in renaming nodes. However, later it turned out that having this feature disabled introduced other test issues. We have been (and still are) trying various configurations of IE driver capabilities without achieving a state in which there would be no test blocking issues.

What is still unclear is the connection between 'mouseover' event (used to implement persistent hovering) and the canvas refresh that seems to handle events unrelated to mouseover (EVENT_DRAGDROP_END and EVENT_SHAPE_ADDED [1]). If this connection could be tracked (any ideas Tihomir?), then perhaps it would be possible to alter Designer code in a way that mouseover events would no longer trigger refreshCanvasforIE function. We believe this would get our tests running on IE11 again.

The other possibility is to fix the rendering issue itself so that refreshCanvasforIE would become unnecessary.

[1] https://github.com/droolsjbpm/jbpm-designer/commit/8a2e7aadf78ad5825c64715de0fc6e5995571e0d#diff-f2cadd5789b6e90ff2b2eccc3559e0ceR52

Comment 9 Jeremy Lindop 2015-02-10 13:20:29 UTC
Created attachment 990089 [details]
IE11CannotNameElement6.1.0ER3

Problem reproduced without Selenium driver.

Comment 10 Jeremy Lindop 2015-02-10 13:21:27 UTC
Created attachment 990090 [details]
IE11CannotNameElementCurrent

Problem may be fixed with current development build.

Comment 11 Jeremy Lindop 2015-02-10 13:22:31 UTC
I'm hopeful that this problem is fixed by the fix to
https://bugzilla.redhat.com/show_bug.cgi?id=1145522

If you look at the Start node in the attachment 'State of screen...', you'll see that the node has buttons for adding nodes above and to the right of the icon, but the shape-menu button (yellow spanner) below the node is missing. This is a symptom of BZ1145522 where in IE11 nodes look as though they are selected but they're not fully functioning. I think the fact that you can't name the node when it's in this state is a symptom of this problem.

I've reproduced the bug using 6.1.0.ER3, using IE11 without the Selenium driver running (see attachment). Then I retested with our current development build (also see attachment) and the fix to BZ1145522 has fixed the problem.

Comment 12 Jeremy Lindop 2015-02-11 16:37:12 UTC
Hi Jiri,
re: comment 8

Can you tell me how you found that refreshCanvasforIE is triggered by MOUSEOVER events?  I've tried adding code to view.js to see this happening but am not seeing  refreshCanvasforIE being triggered.

Thanks
Jeremy

Comment 13 Jiri Locker 2015-02-11 17:18:47 UTC
(In reply to Jeremy Lindop from comment #12)
> Hi Jiri,
> re: comment 8
> 
> Can you tell me how you found that refreshCanvasforIE is triggered by
> MOUSEOVER events?  I've tried adding code to view.js to see this happening
> but am not seeing  refreshCanvasforIE being triggered.
> 
> Thanks
> Jeremy

When I observed a test running with IE driver, I saw frequent refreshes (flickering of the canvas), which I *guess* might be an effect of the refreshCanvasforIE function. After turning off IE driver feature called persistent hovering, the flickering stopped and the test was able to set element name.

IE driver documentation states that persistent hovering is achieved by repeatedly firing MOUSEOVER event at cursors last known location. From this I concluded there may be a connection between MOUSEOVER and refreshCanvasforIE. I wasn't successful in finding a proof for this *hypothesis*.

Comment 14 Jeremy Lindop 2015-02-12 12:32:26 UTC
Running an automated Selenium test on IE11, the attached reproducer project works - the start node is successfully renamed.

The following commit fixes the refreshCanvasforIE function so that automated tests are able to select and move nodes in the diagram:

master: https://github.com/droolsjbpm/jbpm-designer/commit/f9930a542ed5e6d5eb6527e5afb9b26c4763db10
6.2.X: https://github.com/droolsjbpm/jbpm-designer/commit/654af3f1a062b07e4c1e269ad150c5b6f166dbbf

Comment 15 Sona Mala 2015-03-19 16:50:23 UTC
This issue was verified on 6.1.0 ER6.

I can confirm that tests can set names of elements on the 1th process level. The reproducer passed. The 2nd+ level is blocked by bz 1203382.


Note You need to log in before you can comment on or make changes to this bug.