Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

client.isActive() does not work consistently with Table when testing with QFTest/Testbench #5052

Closed
vaadin-bot opened this issue Apr 8, 2014 · 6 comments
Labels

Comments

@vaadin-bot
Copy link
Collaborator

Originally by @johannest


In some cases client.isActive() seem to return false even when the rendering is not completed. This results "Communication problem" notification when playing back tests recorded with QFTest and also with TestBench sometimes.

Unfortunately, there is currently no reliable way to reproduce the issue. But, it seem to be happen when Table is resizing. The problem might be that Table's client side uses timer(s) for size calculation and client.isActive() does not reckon those.

I will add more information if something more precise turn up.


Imported from https://dev.vaadin.com/ issue #13565

@vaadin-bot
Copy link
Collaborator Author

Originally by @Legioth


Yes, we are familiar with this phenomenon. Teemu was doing something about this for some of our internal tests some weeks ago, but I don't remember whether the root issue was actually fixed or just temporarily workarounded by adding delays to our tests.

@vaadin-bot
Copy link
Collaborator Author

Originally by @Artur-


client.isActive() does not necessarily wait for rendering to complete but for no active server communication to take place. Typically these kind of issues can be worked around by waiting for some element to be present before interacting with it. Not sure how QFTest works but a communication error would never be expected by TestBench at least, provided that client.isActive() returned false.

This sounds a bit like the same problem that causes our LayoutTesterApplication to sporadically capture incorrect screenshots. On the other hand, that is only a screenshot comparison issue, it does not cause communication error.

@vaadin-bot
Copy link
Collaborator Author

Originally by @Saulis


Let's create a interface (Jonatan will provide nice naming for us) that can be used to ask a client component if it has any pending actions going on. Then, the ApplicationConnection should use this interface in it's isActive() method.

@vaadin-bot
Copy link
Collaborator Author

Originally by @Artur-


This could be

/** Gives widgets the possibility to indicate to the framework that there is work  
 - scheduled to be executed in the near future and that the framework should wait 
 - for this work to complete before assuming the UI has reached a steady state.
*/
public interface DeferredWorker {
    /** @returns true, if there are operations pending which must be executed before reaching a steady state */
    public boolean isWorkPending();
]

@vaadin-bot
Copy link
Collaborator Author

Originally by @Artur-


In what way is this pending design?

@vaadin-bot
Copy link
Collaborator Author

Originally by Markus Koivisto


https://dev.vaadin.com/review/#/c/4152/

@vaadin-bot vaadin-bot added the bug label Dec 10, 2016
@vaadin-bot vaadin-bot added this to the Vaadin 7.3.0.rc1 milestone Dec 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant