cancel
Showing results for 
Search instead for 
Did you mean: 

IE crash problems when using TestComplete

SOLVED
Highlighted
Frequent Contributor

IE crash problems when using TestComplete

Hello,  

 

I am launcing the IE browser through Test Complete but it crashes after alternate runs. It work for 1st Run and 2nd run it will crash, it will run for 3rd run and then it will crash 4th Run, this is happening ongoingly. 

 

Regards,

 

Nimish 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Hero

Re: IE crash problems when using TestComplete

So, it crashes on launch?  Is that what you're saying?  If that's the case, then no, I'm not experiencing that problem.

 

Something you need to make sure of... IE sometimes tends to hang around in process memory after it has been closed.  When you close a browser instance, you should make sure all copies of the process have been closed as well.  I've experienced situations where, if I didn't do this, a number of strange problems would happen.  

 

The following code is what I use to ensure this

function closeIEInstance() {
    var counter = 0;
    var browser;
    browser = Sys.WaitBrowser('iexplore', 1000);
    while((browser.Exists) && (counter < 60)){
        counter++;
        browser.Terminate();
        browser = Sys.WaitBrowser('iexplore', 1000);
    }  
} 

Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
5 REPLIES 5
Community Hero

Re: IE crash problems when using TestComplete

What version of TestComplete?

What does your code look like?

What are you doing in your tests with IE?

 

I use IE all the time with TestComplete and, while occasionally I get a browser crash, not nearly that frequently and I have my automation set in such a way that it doesn't impact my tests.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Frequent Contributor

Re: IE crash problems when using TestComplete

Hello Robert, 

 

What version of TestComplete?

It is TestComplete 12.6

What does your code look like?

Browsers.Item(btIExplorer).Run ("http://denu00ms0087.phoenix.loc:82/jde/E1Menu.maf")

Also, I tried using TesttedRun.URLName.Run. But still IE is failing frequently. 

 

What are you doing in your tests with IE?

I am launching the browser with the application URL. 

 

Please let me know how to resolve this issue. 

 

Regards,

 

Nimish

 

Community Hero

Re: IE crash problems when using TestComplete

So, it crashes on launch?  Is that what you're saying?  If that's the case, then no, I'm not experiencing that problem.

 

Something you need to make sure of... IE sometimes tends to hang around in process memory after it has been closed.  When you close a browser instance, you should make sure all copies of the process have been closed as well.  I've experienced situations where, if I didn't do this, a number of strange problems would happen.  

 

The following code is what I use to ensure this

function closeIEInstance() {
    var counter = 0;
    var browser;
    browser = Sys.WaitBrowser('iexplore', 1000);
    while((browser.Exists) && (counter < 60)){
        counter++;
        browser.Terminate();
        browser = Sys.WaitBrowser('iexplore', 1000);
    }  
} 

Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Community Manager

Re: IE crash problems when using TestComplete

Hi @nimishbhuta,

 

Did Robert's suggestion help you resolve the issue?

---------
Tanya Gorbunova
SmartBear Community Manager

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others.↓↓↓↓↓
Frequent Contributor

Re: IE crash problems when using TestComplete

Sorry for responding late. Yes Robert suggestion has helped me to resolve this issue. For closing, the browser, we need to use .terminate rather than close. Once I made this small change, IE is not crashing anymore. 

 

Thanks Robert....

 

 

Regards,

 

Nimish

New Here?
Join us and watch the welcome video:
Top Kudoed Authors