NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

I want to display the number of Passed / failed tests in Testtand xml report , please help me

Solved!
Go to solution

Hi, I want to display the number of Passed / failed tests in Testtand xml report , please help me.

My requirement is later i should be able to display these number of passed/failed test in report header too.

0 Kudos
Message 1 of 5
(5,485 Views)

You will have to us the ModifyReportHeader callback. The header will be generated in the TestReport callback in the processmodel. 

Have a look at the callback and post back if you have any questions.

 

Thanks,

Sathish 

0 Kudos
Message 2 of 5
(5,481 Views)

If you know about  XML a bit,  you can edit the XML string to update the No of Failed/Passed steps in the Report,

 

http://forums.ni.com/t5/NI-TestStand/Data-from-text-file-to-report-header/m-p/1458376#M31966 , this link is about adding the Some data to the Report Header  in your case you have to Get the count of Passed/Failed Steps and update in the "Title" attribute. It will be Shown in the Report

 

If you are looking for adding other information in the XML, you have to work a little by appending new node in the XML and have to modify the Style Sheet to get apperaed in the Report.

 

 

AshwiN,

 

 

0 Kudos
Message 3 of 5
(5,477 Views)
Thanks satish for ur response, Actualy i have more than 300 test steps in my sequence file, I want to craeate 2 variables like pass and fail where i can store the count number of passed and failed tests in respective variables. count of passed or failed variable should increment as tests passes or failes, finaly i shud have total number of passed & failed tests inthese variables. I am using the following expression in the post expression of the every numeric test(evaluation) and pass/fail test i have used in my all sequence calls. .(Step.Result.Status=="Passed")?FileGlobals.fail++:FileGlobals.pass++ But i have problem in displaying the exact number of passed/failed tests. and i am getting some incorrect count. Then i have to display these variables in the report header.
0 Kudos
Message 4 of 5
(5,476 Views)
Solution
Accepted by topic author 2481505

I have attached a sequence to give you an idea of how to get the Result count (I didn't check it's working Smiley Wink ), I have used "SequenceFilePostResultListEntry" callback to calculate the Result Count,

 

and the Result Count is passed to the "ModifyReportHeader" through File Globals,  where you can edit the XML file to show it in the Repot (follow the link in my previous post).

 

 

Hope this helps

 

 

AshwiN,

 

0 Kudos
Message 5 of 5
(5,467 Views)