-
Notifications
You must be signed in to change notification settings - Fork 23
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
Karma fails to capture IE when run from OSX through VMWare Fusion #4
Comments
Moving discussion from #3: @pouncilt said:
|
@pouncilt - What you're describing sounds like a very odd usage scenario. If you're trying to launch IE on a windows vm from an instance of Karma running on the host mac system, there is going to be some interesting acrobatics occurring to make this happen. Are you running Karma from a windows cmd shell? |
@pouncilt said:
|
@pouncilt - You are correct, this issue is similar #3, but these really are different issues. The root cause for the other issue is a combination of running on widows 8 64-bit and karma trying to launch 32-bit IE. Because of this, the workaround listed in the other issue will not fix this issue. My best guess at a workaround for this issue is completely different from #3. Please try the following:
I believe this will work (assuming your project can run on windows), but it may not. Please tell me your results. |
The original scripts that was used to get all this working can be found here: https://github.com/angular/ci.angularjs.org/tree/master/bin. I downloaded the ie8.sh and i.e_.sh files. I ran into problems running the ie8.sh because it could not resolve the location to the i.e_sh file via the ". i.e_.sh" at the end of the file. So I added the absolute directory in front of the i.e_.sh file name and I renamed the i.e_.sh file to i.e.sh and I updated the ie8.sh file to: VMNAME="Win7_IE8" . $DIR/ie.sh [Start of i.e_.sh file] export PATH="/Applications/VMware Fusion.app/Contents/Library/":$PATH winExec() { killIe() { trap "killIe; exit 0" EXIT echo -e "\n\n\n----------------+ captureUrl=$1 Here are the steps to install and run IE8 from mac:
export PATH="/Applications/VMware Fusion.app/Contents/Library/":$PATH winExec() { winExecute() { killIe() { trap "killIe; exit 0" EXIT echo -e "\n\n\n----------------+ captureUrl=$1 #winExecute "C:\Program Files\Internet Explorer\iexplore.exe" ${captureUrl/localhost/[Mac IP Address Here]}
WshShell.Run strIE & " " & objArgs(0) So I don't know why Karma keeps crashing. Any help to resolve this would be deeply appreciated. Thank you. |
Thanks. In your last step you said, that IE8 launches and runs all your tests and then reports a crash at the end of the the run. Did I read that correctly? In your first update of What about the work around steps I suggested? I know they are not a viable option long term, but then you would at least have runable state while we figure this out. |
The VMWare Fusion logs go in there. For example if you have the wrong user name and password, VMWare Fusion will log this error in the log file. Or if you try to start Karma before you start VMWare Fusion, VMWare Fusion will tell you that the VM has not been started. Yes, you read me correctly - IE8 successfully launches and runs all my Jasmine test successfully and then Karma crashes once all the test have rand. When you start Karma in continuous integration mode it is supposed to stay running and connected to the browsers, and re-run the Jasmine tests if and when the code changes. WinExecute() method is actually the original method. The only thing that is different from the original method is the name "winExecute()". I needed to keep the original winExecute() method in order to properly kill the browsers regardless if the browsers are running on VM or locally and whether or not the browsers are IE, FF, Chrome, or Safari. You will notice that the winExecute() method is only called from the killIe() method. In addition to this, you should notice that I changed the winExec() method in the else block to run the csscript.exe and that this winExec() method is only called at the end of the script; which is where I pass in the VBscript and Karma URL. In addition to seeing that the %22 being added to the beginning of the URL, you should also see an actual double quote at the of the URL. At least, that is what I am seeing. I didn't try the work around you suggest because I am able to start the IE8 browser in the VM and run my tests. Until this issue is resolved, I will just have to keep killing Karma server after each test run because Karma thinks that the browser has crashed. In reality the browser doesn't really crash. The script receives an exit 0 code and calls the killIe() method. If I comment out the trap statement the browser would still be open. I am glad that you are taking a look at this. I really appreciate this. Let me know if you were able to follow my steps to reproduce this issue. If you are able to reproduce, are you seeing the same things I am seeing? You can get a 30 day trail version of VMWare Fusion to test with. Thank you. |
This patch tries to auto-detect 64-bit IE by checking for the appropriate environment variables. It also improves reliability of the tests by disabling extensions and using "InPrivate" mode to ignore existing user data. Addresses karma-runner#1, karma-runner#2, karma-runner#4, and possibly karma-runner#8.
Can anybody double-check whether this issue is fixed in 0.1.2 please? |
(similar repro steps to #3 ).
Repro:
Expected:
karma to launch and capture IE, run tests, exit and close IE
Actual:
karma launches IE three times and believes IE has exited each time.
Windows version can be 32-bit or 64-bit, can be window xp or greater.
The text was updated successfully, but these errors were encountered: