cancel
Showing results for 
Search instead for 
Did you mean: 

Email Test Results as a small txt file

SOLVED
Highlighted
Contributor

Email Test Results as a small txt file

Is there a way to convert test results to small txt file and email it?



I used slPacker and SendMail methods to pack and email an mht file. It works fine when I run just a few test scripts but there is a problem when I run a lot of them. The mht file becomes to big and is rejected by smtp.



I only need test script name and execution result. If there was at least one error during test run I can assume that this test failed.
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Valued Contributor

RE: Email Test Results as a small txt file

It sounds like you're just looking for a summary of the log file results.

I would recommend reading the Log.ErrCount and Log.WrnCount properties of the log to compose your email text body. You don't need to include this as a text file attachment to accomplish this.

''-Praise the sun and Give Kudos.''

View solution in original post

3 REPLIES 3
Highlighted
Valued Contributor

RE: Email Test Results as a small txt file

It sounds like you're just looking for a summary of the log file results.

I would recommend reading the Log.ErrCount and Log.WrnCount properties of the log to compose your email text body. You don't need to include this as a text file attachment to accomplish this.

''-Praise the sun and Give Kudos.''

View solution in original post

Highlighted
Contributor

RE: Email Test Results as a small txt file

Thanks Ryan. Do I need to add this procedure to each one of my tests?
Highlighted
Valued Contributor

RE: Email Test Results as a small txt file

You'll want to catch the OnStopTest event in each project and have the referenced function send the email.

''-Praise the sun and Give Kudos.''
New Here?
Join us and watch the welcome video:
Announcements
Script Wanted
Let's start July with new challenges!

Create a script to pass custom command-line arguments as a test parameter for the TechCorner tag!

Will you dare to take the challenge?


Top Kudoed Authors