-
-
Notifications
You must be signed in to change notification settings - Fork 21
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
It's closing for no reason #27
Comments
Hey! Can you check which version are you running under composer.lock? |
|
|
When this happens to me (with Java and Selenium) it is because of the different version between the browser and the driver. |
@stonkeep hmmm. Which version of Chrome are you running? |
I am having the same issue, when running magic, the browser appears for a couple hundred milliseconds and immediately disappears. If I insert a few assertions, the browser will stay open long enough to run the assertions, but as soon as it hits the magic function, the browser disappears. I am running this in a Laragon (4.0.16.190914) environment on Windows. Do you have any suggestions for where I can work to start troubleshooting this? |
Any updates for this issue? I am experiencing the same thing. |
The Last one |
@fs-csmith please update your Magic Test dependency |
Please make sure you're on the latest version of the package. What do you see on composer list? |
I need to know the exact version please |
Thank you for your reply. To the best of my knowledge I am on the most current versions. Chrome recently updated so that version has changed since my last post. Currently, I am running: Laragon (4.0.16.190914) environment on Windows. To eliminate the Laragon environment, I tried running on php artisan serve and got the same behavior. I appreciate your help. |
To be more clear when running magic in my terminal, I get a message DevTools listening on ws://.... followed by a handful of errors
I initially ignored the errors as they seemed to be issues with the chromedriver that just needed to be cleaned up by them, but perhaps it is applicable to this issue? And, I get the error even when no devices are connected. |
@fs-csmith I got access to a Windows computer and I'll try to reproduce your bug. Thanks for following the thread! |
Hello @mateusjatenee , Is there any update on this issue? Thank You. |
Hey Mohamed, I've tried it on Windows and it worked fine. My time is a bit tight to pursue this further on Windows since I don't use it, so any help is very much appreciated. |
@mateusjatenee I have the same issue, I just see the chrome window briefly and then it closes. |
Thanks Daniel. Are you on Windows? |
Yes I am on windows, fresh laravel application. It opens, i see the default laravel welcome page and then it closes. Feels like it doesn't 'detect' the magic call |
I have an example repository that didn't work for me and a colleague. Maby it's handy for you debugging: https://github.com/DanielvdSpoel/magictesten |
is there any update on this? I having same issue here, the browser suddenly closed, I using same Chrome driver version with my installed Chrome |
@mateusjatenee do you have a update on this? |
I haven't tested it again |
@stonkeep @DanielvdSpoel Sorry, I don't have a Windows machine to test. I will ask a few colleagues to maybe reproduce the error and help me figure out what it is. |
Same problem here. I am using Laragon and Laravel 8 on Windows. I tried an older chromedriver... When i start magic chrome appears and disappears two times |
This is probably because Windows doesn't support TTY. I think this manages the terminal connections. So when the magic test starts it tries to create a new Psy Shell (to ask for input). But since there is no TTY, it just skips this part and closes the browser (because it thinks it has completed the magic test steps). This problem only exists on Windows itself (with for example Laragon). If you try this via WSL (Windows Subsystem for Linux), it'll probably work since that does have TTY support. I've tried some ways to make this work with Windows/Laragon but I just can't get the MagicTestManager run function to 'talk' to the CMDER that Laragon uses. TLDR; |
Hello @mateusjatenee , |
@prakashhalder what applications are you using? For example Laragon or WSL (Windows Subsystem for Linux)? |
I am using xampp |
Is this message popping up in your console by any chance? |
Yes, I am getting "Warning: TTY mode is not supported on Windows platform." |
See my comment:
You can't fix this problem on Windows, because it simply does not support it. Only way you can get it to work on Windows is by installing WSL. See: https://learn.microsoft.com/en-us/windows/wsl/install |
Still I am unable using WSl, I am getting error like |
This is a whole other error. You can try a few things:
|
Have you followed the installation steps for magic tests?
If this is the case, please share more information on what you are trying to test and with what code. |
@prakashhalder sadly I cannot help you further without debugging the project myself. I would recommend diving into the magic test package and trying to find where it stops or doesn't give any more output. |
@ITMobilityControl Appreciate your help here. 🙏🏻 I'll have access to a Windows machine for a few days and I'll try to debug this. It's really hard since it isn't reproducible in Linux/Mac, and apparently doesn't happen in WSL. |
@ITMobilityControl |
I just run
php artisan magic
The browser open and close
My test:
The text was updated successfully, but these errors were encountered: