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

Sample Tests Consistently Fails On Before Hook With Chrome (Mac) & Edge (Win) Browsers #17

Open
bhreinb opened this issue Aug 17, 2018 · 2 comments

Comments

@bhreinb
Copy link

bhreinb commented Aug 17, 2018

Hi there,

I ran the sample tests on a few browser configurations. I notice though the tests fail at the Before hook stage on some configuration types (chrome Mac) & (edge win). I think it fails at the 'waitForTestController' API call. It seems to fail on the second test for each feature file.

✖ Before # features/support/hooks.js:46
Error: function timed out, ensure the promise resolves within 20000 milliseconds
at Timeout._onTimeout (/Users/bhrein.brannick/Documents/src/testcafe-cucumber/node_modules/cucumber/src/user_code_runner.js:61:18)
at ontimeout (timers.js:498:11)
at tryOnTimeout (timers.js:323:5)
at Timer.listOnTimeout (timers.js:290:5)

I guess this is a different type of failures as sample test scenario number 4 fails as expected due to a test assertion error, however what I describe above is due to setup failures. Incidentally the sample tests run ok (chrome win), (ie win) & (firefox Mac & Win). Let me know if you need any more info.

@rquellh
Copy link
Owner

rquellh commented Sep 9, 2018

I think the latest release might clear some of this up. I checked Edge 42 on Windows 10. The only odd thing is it creates a new tab instead of closing the browser entirely. I'll continue to look into that issue.

@bhreinb I don't have access to a Mac to check the Mac/Chrome issue that you were having. Could you pull the latest and check this issue for me? Thanks.

@bhreinb
Copy link
Author

bhreinb commented Oct 14, 2018

Hi @rquellh

I pulled the latest from your repo. Unfortunately the tests still fail on Mac albeit its not down to an issue with this project but more so a TestCafe item

DevExpress/testcafe#2835 (comment)
DevExpress/testcafe#2918

Edge I solved by adding some custom code to hooks to forcibly close the event loop in cases where Testcafe continues to maintain a connection reference to the browser (edge & safari tends to exhibit that behaviour).

You can see my sample project here

https://github.com/bhreinb/SYSTAC

I took a-lot of the concepts that were done in this project and refined them there with some further enhancements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants