Ask a Question

Should Test Execute honor on error properties?

SOLVED
stampy986
Occasional Contributor

Should Test Execute honor on error properties?

Hi all, I have some tests failing with TE that are not failing when I run TC.

Scenario: I have an application that is only part of the main overall build. When I launch it standalone, it throws a crash in the background that’s expected because it’s looking for another part of the build that is not there. User doesn’t see the crash.

Now when I set up my environment in TC, I said continue running on error, and set up that step to not log the error. The whole suite of tests pass. When I move it to TE to run, it fails immediately when it sees the background crash and I cannot run my test.  Is there something I am missing and can I get test execute to ignore the crash? 

 

Error handling.pngEnvironment.pngScript1.png

 

 

 

8 REPLIES 8
tristaanogre
Esteemed Contributor

Technically speaking, those settings are stored in the project.  I believe in the MDS file.  If that file has not been copied to the new machine properly, that would cause this difference in behavior. 


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available
stampy986
Occasional Contributor

Unfortunately it the same machine, I am just kicking off test execute to run it.

tristaanogre
Esteemed Contributor

Double check something.  In your test items, right click and select "Field Chooser".  Then drag in the field for "On exception" and see what the setting for that is.


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available
stampy986
Occasional Contributor

I didnt notice that property before now and it was set to stop on error.   I have changed it to continue, but it did not help. My application still closes when test execute tries to launch it.   It still launches correct through test complete

 

 

tristaanogre
Esteemed Contributor

What are you getting in the log from the TestExecute runs?  Is there anything present in the log output?  Generally speaking, there should be no difference running on TE versus TC so I'm wondering if you're running into some other problem and not this one.


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available
stampy986
Occasional Contributor

I agree, I think TC and TE should be the same,  but I cant see what else it could be.  

 

I created a new blank project to simplify everything.   

 

First test is TC:

I set all the project properties to continue running:

TestedApp I launch with script:

 

function RunWellExplorer()
{
//Log.Enabled=false
Delay(3000)
TestedApps.WellExplorer.Run()
Delay(30000)
//Log.Enabled=true
}

 

 Testedapp.png

Run TC:

After about 20 seconds my app launches alongside TC as seen in image below.  It shows the error which is expected since I have logging turned on.  

TCWE.png

error.png

 

Close TC and open TE:  My app briefly try to open after 20 seconds it closes.   Same Error as TC by no app running. 

TEWE.png

 

In the event logger of windows, the errors are the same except for the case, but that shouldn't matter.  

TCEvent.pngTEevent.png

 

 

 

stampy986
Occasional Contributor

Error: Same for both TC and TEerror.png

 

I started with a clean new project and only put 1 test in to simplify things:

 

TC test first:

I ran a tested app with the script below:

 

function RunWellExplorer()
{
Log.Enabled=false
Delay(3000)
TestedApps.WellExplorer.Run()
Delay(30000)
Log.Enabled=true
}

 

Testedapp.png

 

After about 20 seconds my app was open on the left with the error I expected in the log:

TCWE.png

Closed TC and launched TE, ran the same script.  My app tried to start and closed after about 20 seconds.  Everything appears the same as TC

TEWE.png

 

In the windows event logger, same error only the case is different.  

TCEvent.pngTEevent.png

TanyaYatskovska
SmartBear Alumni (Retired)

Hi @stampy986,

 

It makes sense to consult with the TestComplete Support Team. Could you please contact them here? https://support.smartbear.com/message/?prod=testcomplete

 

---------
Tanya Yatskovskaya
SmartBear Community and Education Manager



cancel
Showing results for 
Search instead for 
Did you mean: