diff -r b31261fd4e04 -r ccd8e69b5392 tsrc/scripts/EunitRunner.pl --- a/tsrc/scripts/EunitRunner.pl Tue Feb 02 00:09:07 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,721 +0,0 @@ -# -# Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -# All rights reserved. -# This component and the accompanying materials are made available -# under the terms of "Eclipse Public License v1.0" -# which accompanies this distribution, and is available -# at the URL "http://www.eclipse.org/legal/epl-v10.html". -# -# Initial Contributors: -# Nokia Corporation - initial contribution. -# -# Contributors: -# -# Description: -# -#!perl -#line 5 - -#-------------------------------------------------------------------------------------------------- -# This Script will be used to run EUnit testcases -# Example Usage in Nightly build script -# my $currentdir = cwd; -# chdir "$ProjLocation\\mmsharing\\internal\\group"; -# system ("EunitRunner.pl -command=eu -all -dest=$Plog -summary=$Plog\\scanlog.html 2>&1 >> $Plog\\EUnit.log"); -# system ("EunitRunner.pl -command=ctc -all -dest=$Plog -summary=$Plog\\scanlog.html 2>&1 >> $Plog\\CTC.log"); -# chdir $currentdir; -# Version : 1.0 -#-------------------------------------------------------------------------------------------------- - -# Perl packages used. -use File::Find; # File operations -use XML::Simple; # XML parsing -use File::Spec::Win32; # File operartions -use Getopt::Long; # parameter handling -use Cwd; # Directory operations - -# Parameters related to Epoc. -my($build_destination_dir)= "\\Epoc32\\release\\winscw\\udeb\\"; -my($build_tools_dir)= "\\Epoc32\\tools\\"; - -# Parameters related to Digia Eunit. -my($eunit_xml_file_name)= "EUnit_Log.xml"; -my($eunit_xml_file)= "\\Epoc32\\winscw\\C\\shared\\EUnit\\Logs\\".$eunit_xml_file_name; -my($eunitParams) = "/l xml /e S60AppEnv /w 40 /p All /t 50"; -my($eunitParams2) = " /d alloc"; -my($eunitApp) = "/epoc32/release/winscw/udeb/EUnitExeRunner.exe"; -my($eunit_destination_dir)= "\\Epoc32\\release\\winscw\\udeb\\z\\sys\\bin\\"; -my($unittest_result_file)="eunit_result.html"; - -# Parameters related to Codetest(ctc). -$coverageSymbols = "MON.sym"; -$ctcCommandPart1 = "ctc-abld-winscw -i d -n"; -$ctcCommandPart2 = "-- test build winscw udeb"; -$ctcIgnoredPart1 = " -C \"EXCLUDE+*/internal/*.cpp"; -$ctcIgnoredPart2 = "\""; -$coverageProfile = "profile.txt"; -my($ctc_result_file)="./\CTCHTML/\indexF.html"; - -# Parameters related to filenames. -#my($overal_summary_file)="Overall_Summary.html"; -my($overal_summary_file)="scanlog.html"; - -# Hack : This will be used if dll names are not retrived from build environment. -my(@default_subsystems)=("UT_AVAILABILITY", - "UT_AOPLUGIN", - "UT_SIPCRPLUGIN", - "UT_MUSAIWPROVIDER", - "UT_MUSWPADAPTER", - "UT_MUSMANAGERCLIENT", - "UT_MUSMANAGERSERVER", - "UT_MUSENGINE" ); -my(@default_dll_filenames)=("UT_AVAILABILITY.DLL", - "UT_AOPLUGIN.DLL", - "UT_SIPCRPLUGIN.DLL", - "UT_MUSAIWPROVIDER.DLL", - "UT_MUSWPADAPTER.DLL", - "UT_MUSMANAGERCLIENT.DLL", - "UT_MUSMANAGERSERVER.DLL", - "UT_MUSENGINE.DLL" ); - - -my @uncompiled_sub_systems;# Holds list of uncompiled subsystems . Will be printed in report later. -my($currentdir)= cwd; # Current working directory. -my($results_destinationdir)=cwd; # Results will be stored here. -my($results_destinationdir_log)=cwd; # Log prints will be stored here. -my ($unittest_log_file) = "EUnit.log"; # Eunit build process logs will be in this file. - -# Parameters related to result prints -my($eunit_passpercent, - $eunit_failpercent, - $eunit_total_pass_count, - $eunit_total_fail_count, - $eunit_total_count, - $eunit_total_pass_percent); -my(@eunit_testsuite_name, - @eunit_testsuite_total_testcase, - @eunit_testsuite_pass_count); - -# Parameters related to globally used variables. -my (@subsystems, # List of user selected sub systems - @sourcefiles, # List of user selected source files - @exclude_sourcefiles, # List of test source files. - @makefiles, # List of make files - @dll_filenames); # List of dll file names - -my ($param_help, # To view help - $param_command, # Command to Run - $param_dest, # Copy results to - $param_all, # Build all - $param_noclean, # Do not run abld clean - $param_nobuild, # Do not run abld build - $param_nostub, # Do not build stub - $param_exe, # Specify exe file to be run instead Eunirexerunner.exe - $param_overall_summay, # Overall Summary - $param_version); # Version -my @gloabl_errors; - -# Parameters for user choice. -my($choice, - $user_selection, - $count); - -#-------------------------------------------------------------------------------------------------- -# Main -#-------------------------------------------------------------------------------------------------- - -#************************************************************************************************** -# Read commandline options. -#************************************************************************************************** -my $result = GetOptions('help' => \$param_help, # Display help info - 'command=s' => \$param_command, # Command to run - 'dest=s' => \$param_dest, # Destination directory - 'all' => \$param_all, # Run all - 'noclean' => \$param_noclean, # Dont run reallyclean - 'nobuild' => \$param_nobuild, # Dont run symbian build commands - 'nostub' => \$param_nostub, # Dont build stupbs - 'exe=s' => \$param_exe, # Launch the exe specified.if nothing then epoc will be used - 'summary=s' => \$param_overall_summay, # Launch the exe specified.if nothing then epoc will be used - 'version' => \$param_version); # Version Information - -#Test -#my $mapped_drive = "\\\\Vagrp006\\groups5\\SP_IDO\\IPASDo_MSDo"; -#$results_destinationdir = "$mapped_drive\\Builds\\multimediasharing\\3.2\\NightlyBuilds\\2008-wk8\\18-Monday\\Log\\EUnitAndCTC"; -#exit 1; - -#************************************************************************************************** -# Step 1 : Pre Cleanup. -#************************************************************************************************** - run_system_command("del "."$eunit_destination_dir"."*.dll"); - run_system_command("del "."$eunit_xml_file"); - -#************************************************************************************************** -# Step 2 : Check pre-conditions. -#************************************************************************************************** - if (! -e $build_destination_dir."EUnitExeRunner.exe") - { - print "*** EUnit is not installed for this SDK ***\n"; - exit 1; - } - -#************************************************************************************************** -# Step 2 : Check command line parameters and configure if not present to default. -#************************************************************************************************** - if(defined $param_overall_summay) - { - $overal_summary_file = $param_overall_summay ; - } - if ($param_command eq ('ctc'|'CTC'|'Ctc') ) - { - $choice=1; - } - elsif ($param_command eq ('eu'|'EU')) - { - $choice=2; - } - else - { - usage(); - } - $param_exe=$eunitApp if(!defined $param_exe); - if(defined $param_dest) - { - $results_destinationdir=$param_dest ; - } - else - { - print "\n Note: No results destination directory specified. Results will be copied to $currentdir/\Eunit\n"; - } - $results_destinationdir=~s/\//\\/g; - $results_destinationdir_log = "$results_destinationdir";# This is were logs are stored in nightly build env. - run_system_command("mkdir $results_destinationdir\\EUnitAndCTC") if (! -e "$results_destinationdir\\EUnitAndCTC"); - $results_destinationdir="$results_destinationdir\\EUnitAndCTC"; - $param_noclean=1 if(defined $param_nobuild); - $ENV{'CTC_DATA_PATH'}= ""; - run_system_command("bldmake bldfiles") if (!defined $param_nobuild); - -#************************************************************************************************** -# Step 3 : Display subsystems to user. So he can make a choice for which one to compile -# if command line parameter -all specified then it will not be shown. -#************************************************************************************************** - display_sybsystems(); - if(defined $param_all) - { - print "\nOptions -all specified.Building all components \n "; - $user_selection=0; - } - else - { - print "\t Options selected : "; - $user_selection = ; - chomp ($user_selection); - exit 0 if $user_selection =~ /^[Qq]/; - } - -#************************************************************************************************** -# Step 4 : Build subsystems. -#************************************************************************************************** - if(!$param_nostub) - { - print "\n *** Building unittest stubs ***\n "; - run_system_command("abld reallyclean winscw udeb"); - run_system_command("abld build winscw udeb"); - print "\n *** End of building stubs ***\n "; - } - if (!defined $param_nobuild) - { - print "\n *** Building test components ***\n"; - if($choice==1) - { - $ENV{'CTC_DATA_PATH'}= $currentdir; - build_user_selected("$ctcCommandPart1 $coverageSymbols $ctcIgnoredPart1 $ctcIgnoredPart2 $ctcCommandPart2"); - } - elsif($choice==2) - { - build_user_selected("abld test build winscw udeb"); - } - print "\n *** End of Building test components ***\n "; - } - -#************************************************************************************************** -# Step 5 : Run EunitRunner.exe . -#************************************************************************************************** - print "\n *** Running EUnit with selected subsystems ***\n"; - chomp(@dll_filenames); - if( scalar @dll_filenames eq 0 ) - { - print "Can not find dll names automatically.Using default configured values\n"; - @dll_filenames = @default_dll_filenames; - } - copy_dlls(); # copy dlls to eunit directory - if($choice==1) - { - run_system_command("$param_exe "."$eunitParams");# Run without alloc failure - #run_system_command("$param_exe "."$eunitParams"."$eunitParams2");# Run with alloc failure - } - elsif ($choice==2) - { - run_system_command("$param_exe "."$eunitParams"); - } - -#************************************************************************************************** -# Step 6 : Print Results. -#************************************************************************************************** - print "\n *** Printing Reports ***\n"; - if($choice==1) - { - run_system_command("ctcpost $coverageSymbols $coverageDat -p $coverageProfile -T 70"); - run_system_command("ctc2html -i $coverageProfile -t 70 -nsb"); - run_system_command("xcopy /R/F/Y/I CTCHTML $results_destinationdir\\CTCHTML"); - print_overall_summary_ctc(); - } - elsif($choice==2) - { - print_overall_summary_error();# Mainly needed for nightly build env and for eunit. - print_eunit_html_report(); - print_overall_summary_eunit(); - run_system_command("copy $eunit_xml_file $results_destinationdir\\$eunit_xml_file_name"); - run_system_command("copy $unittest_result_file $results_destinationdir\\$unittest_result_file"); - } -#This reports other script errors which might have harmed the flow of execution. -print_overall_summary_script_error(); - -#************************************************************************************************** -# Step 7 : Post Cleanup. -#************************************************************************************************** - $ENV{'CTC_DATA_PATH'}= ""; - run_system_command("del "."$eunit_destination_dir"."*.dll"); - run_system_command("del "."$eunit_xml_file"); - print "\n *** DONE ***\n"; - -#---------------------------------------Main Ends-------------------------------------------------- - -#-------------------------------------------------------------------------------------------------- -# This sub routine displays all the subsystems to the user. -#-------------------------------------------------------------------------------------------------- -sub display_sybsystems - { - get_subsystems(); - if(scalar @subsystems==0) - { - print "Can't find subsystem name automatically.Using default configured values\n" ; - @subsystems = @default_subsystems; - } - print "\n\tPlease choose an option listed below \n"; - print "\n\tenter +/- to build backward or forward \n"; - print "\t\t0.To build all \n"; - $count=1; - foreach(@subsystems) - { - print "\t\t".$count++. "." .$_."\n"; - } - print "\t\tq.Exit \n"; - } - -#-------------------------------------------------------------------------------------------------- -# Runs abld commands for the user selected choice. -#-------------------------------------------------------------------------------------------------- -sub build_user_selected - { - if($user_selection==0) - { - for($count=0;$count<@subsystems;$count++) - { - run_system_command("abld test reallyclean winscw udeb @subsystems[$count]"); - run_system_command("@_[0] @subsystems[$count]"); - get_dll_names(@makefiles[$count]); - } - } - elsif($user_selection=~/\+/) - { - for($count=substr($user_selection,0,1)-1;$count<@subsystems;$count++) - { - run_system_command("abld test reallyclean winscw udeb @subsystems[$count]"); - run_system_command("@_[0] @subsystems[$count]"); - get_dll_names(@makefiles[$count]); - } - } - elsif($user_selection=~/\-/) - { - for($count=0;$countERROR OCCURED : "."$?"."\n" if(!@_[0]); - print "\n ->ERROR OCCURED : ".@_[0]."\n" if(@_[0]); - #exit 1; - } - -#-------------------------------------------------------------------------------------------------- -# Calls system command and displays error in case. -#-------------------------------------------------------------------------------------------------- -sub run_system_command - { - print " \n -> Command : " .@_[0] ."\n"; - system(@_[0]); - push @gloabl_errors,"Error Occured for Command : @_[0] Error : $?" if($?!=0); - display_critical_error() if($?!=0); - return $?; - } - -#-------------------------------------------------------------------------------------------------- -# Prints Usage. -#-------------------------------------------------------------------------------------------------- -sub usage - { -print< To run CTC. - -eu -> To run EunitTestcases. - -mm -> To run Manual Mode.Useful if you want to find the coverage inside your code. - -resultdir->In where results will be copied. - - Also you can specify some optional flags to change the behaviour of the script. - -all -> To run all subsystems. - -sourcefiles -> To Select Source files for instrumentation - -noclean -> Don't run reallyclean - -nobuild -> Dont run symbian build commands - -nostub -> Dont build stubs - -nosdkinst-> Dont instrument sdk - - Some miscellaneous Commands - -version -> Version Information. - -help -> Usage information. - - Examples : - eunitrunner -command=ctc - eunitrunner -command=eu C:/temp/results - eunitrunner -command=eu C:/temp/results -all - eunitrunner -command=ctc C:/temp/results\ -sourcefiles -nobuild -noclean -nostub - - Note:This script should be run from where bld.inf file available - Note:Also you must specify TEMP environmental variable.(By default this exists in All windows system) -ENDOFUSAGE - exit 0; - } - -#-------------------------------------------------------------------------------------------------- -# Runs abld to make makefile and parse makefile to get subsystems. -#-------------------------------------------------------------------------------------------------- -sub get_subsystems() - { - #Testing prupose to check how abld test makefile command runs. - run_system_command("abld test makefile winscw -w"); - - open WHATCMD, "abld test makefile winscw -w |"; - my @temparray; - while() - { - chomp; - my $makeFile = $_; - if( $makeFile =~ /winscw$/i ) - { - @temparray=split(/\.WINSCW/,$makeFile); - @temparray=split(/\\/,@temparray[0]); - push @subsystems,pop(@temparray); - push @makefiles,$makeFile; - } - } - print "\n Makefiles = @makefiles\n"; - print "\n Subsystems = @subsystems\n"; - close WHATCMD; - } - -#-------------------------------------------------------------------------------------------------- -# Parses makefile to get source files. Useful if you want to run coverage for particular source file. -#-------------------------------------------------------------------------------------------------- -sub get_source_files($) - { - open MAKE, @_[0] or die "Cant open $!"; - my @temparray; - while () - { - my($line)=$_; - if($line=~/(EPOCBLDUREL).*.\.o.*.:.*.\.cpp/) - { - if($line!~/INTERNAL|internal/) - { - @temparray=split(/:/,$line); - @temparray=split(/\\/,@temparray[1]); - push @sourcefiles,pop @temparray; - } - } - } - close MAKE; - } - -#-------------------------------------------------------------------------------------------------- -# Parses makefile to get dll names. -#-------------------------------------------------------------------------------------------------- - sub get_dll_names($) - { - open MAKE, @_[0] or die "Cant open $_ $!"; - my @temparray; - my $dll_name; - while () - { - my($line)=$_; - chomp($line); - if($line=~/Target.*.\.dll/) - { - @temparray=split(/\s+/,$line); - $dll_name=pop @temparray; - chomp($dll_name); - push @dll_filenames,$dll_name; - last; - } - } - close MAKE; - } - -#-------------------------------------------------------------------------------------------------- -# Parses eunit result xml file and prints it as html file. -#-------------------------------------------------------------------------------------------------- -sub print_eunit_html_report - { - my $simple = XML::Simple->new(); - my $struct = eval {$simple->XMLin($eunit_xml_file, forcearray => 1,keyattr => [])}; - push @gloabl_errors,"Invalid XML document Error : $@" if($@); - open(HTML_FILE, ">$unittest_result_file") ||(push @gloabl_errors,"Can not open $unittest_result_file for Eunit" and return); - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "

Overall Result: Passed

Total TestCasesTotal PassedTotal Failed

\n"; - print HTML_FILE "
"; - - foreach my $dll(@{$struct->{dll}}) - { - my $dll_pass_count = 0; - foreach my $mtestsuite(@{$dll->{testsuite}}) - { - foreach my $testsuite(@{$mtestsuite->{testsuite}}) - { - my($testcount)=1; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - foreach my $testcase(@{$testsuite->{testcase}}) - { - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - print HTML_FILE "\n"; - if($testcase->{result}->[0]->{status} eq "OK") - { - print HTML_FILE "\n"; - $eunit_total_pass_count++; - $dll_pass_count++ ; - } - else - { - print HTML_FILE "\n"; - $eunit_total_fail_count++; - } - print HTML_FILE "\n"; - $testcount++; - } - print HTML_FILE "

$testsuite->{name}

NoNameClassMethodTypeResult

$testcount

$testcase->{name}

$testcase->{class}

$testcase->{method}

$testcase->{type}

PASS

FAIL

\n"; - print HTML_FILE "
\n"; - } - push @eunit_testsuite_name,$mtestsuite->{name}; - push @eunit_testsuite_total_testcase,$mtestsuite->{size}; - push @eunit_testsuite_pass_count,$dll_pass_count; - } - } - print HTML_FILE "
"; - $eunit_total_count=$eunit_total_fail_count+$eunit_total_pass_count; - seek HTML_FILE,301,0; - print HTML_FILE "$eunit_total_count"; - seek HTML_FILE,334,0; - print HTML_FILE "$eunit_total_pass_count"; - seek HTML_FILE,367,0; - print HTML_FILE "$eunit_total_fail_count"; - if($eunit_total_pass_count>0 && $eunit_total_count>0) - { - $eunit_total_pass_percent=sprintf "%.2f", (($eunit_total_pass_count/$eunit_total_count)*100); - } - else - { - $eunit_total_pass_percent=sprintf "%.2f","0.00"; - } - seek HTML_FILE,103,0; - print HTML_FILE "$eunit_total_pass_percent%"; - close (HTML_FILE); - } - - #-------------------------------------------------------------------------------------------------- - # Prints overall summary in file specified in command line argument. - #-------------------------------------------------------------------------------------------------- - sub print_overall_summary_eunit - { - open OVER_ALL_SUMMARY, ">>$overal_summary_file" or (push @gloabl_errors,"Can not open $overal_summary_file for Eunit" and return); - print OVER_ALL_SUMMARY "

Eunit Summary

\n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - my($count)= 0; - foreach $_(@eunit_testsuite_name) - { - my $dll_pass_percent = 0; - my $dll_fail_percent = 0; - my $dll_name = @eunit_testsuite_name[$count]; - my $dll_total = @eunit_testsuite_total_testcase[$count]; - my $dll_pass = @eunit_testsuite_pass_count[$count]; - if($dll_total>0 && $dll_pass>0) - { - $dll_pass_percent=sprintf "%.2f", (($dll_pass/$dll_total)*100); - } - else - { - $dll_pass_percent=sprintf "%.2f","0.00 \n "; - } - $dll_fail_percent = 100 - $dll_pass_percent; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - $count ++; - } - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - my $total_eunit_fail_percent = 100 - $eunit_total_pass_percent; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY " \n "; - print OVER_ALL_SUMMARY "
PassRate % - Pass/ all  Subsystem

$dll_pass_percent %   $dll_pass/$dll_total \"\"\"\"$dll_name

$eunit_total_pass_percent %   $eunit_total_pass_count/$eunit_total_count \"\"\"\"OVERALL

\n "; - print OVER_ALL_SUMMARY "View compleate results : $results_destinationdir\\$unittest_result_file \n "; - close OVER_ALL_SUMMARY; - } - -#-------------------------------------------------------------------------------------------------- -#Prints overall summary of CTC in file specified in command line argument. -#-------------------------------------------------------------------------------------------------- -sub print_overall_summary_ctc - { - - open OVER_ALL_SUMMARY, ">>$overal_summary_file" or (push @gloabl_errors,"Can not open $overal_summary_file for CTC \n " and return ); - open CTC_RESULT,"$ctc_result_file"; - @lines = ; - print OVER_ALL_SUMMARY "

CTC Summary

\n "; - print OVER_ALL_SUMMARY " \n"; - print OVER_ALL_SUMMARY "\n"; - print OVER_ALL_SUMMARY "\n"; - print OVER_ALL_SUMMARY "\n"; - foreach $_(@lines) - { - if ($_=~/hr width=/) - { - print OVER_ALL_SUMMARY $_; - } - if ($_=~/img border=/) - { - print OVER_ALL_SUMMARY $_; - } - } - print OVER_ALL_SUMMARY "
TER % - covered/ all  Directory

\n"; - print OVER_ALL_SUMMARY "View compleate results : $results_destinationdir\\CTCHTML\\index.html \n "; - close CTC_RESULT; - close OVER_ALL_SUMMARY; -} - -#-------------------------------------------------------------------------------------------------- -#Check uncompiled subsystems by checking the dll names. -#-------------------------------------------------------------------------------------------------- -sub copy_dlls - { - my $error = 0; - foreach my $dll(@dll_filenames) - { - $error = run_system_command("copy ".$build_destination_dir.$dll." ".$eunit_destination_dir.$dll); - push @uncompiled_sub_systems,$dll if($error!=0) - } - } - -#-------------------------------------------------------------------------------------------------- -# Prints overall error summary if any compilation errors happen. -#-------------------------------------------------------------------------------------------------- - sub print_overall_summary_error - { - open OVER_ALL_SUMMARY, ">>$overal_summary_file" or (push @gloabl_errors,"Can not open $overal_summary_file for Eunit" and return) ; - if (scalar @uncompiled_sub_systems != 0) - { - print OVER_ALL_SUMMARY "

Compilation Errors

\n "; - my $count = 1; - print OVER_ALL_SUMMARY "

Following dll's were not found. Possibly because of build errors! \n

"; - foreach $_(@uncompiled_sub_systems) - { - print OVER_ALL_SUMMARY "

$count. $_

\n"; - $count++; - } - print OVER_ALL_SUMMARY "View Error details : $results_destinationdir_log\\$unittest_log_file \n "; - } - close OVER_ALL_SUMMARY; - } - - #-------------------------------------------------------------------------------------------------- -# Prints overall error summary if any compilation errors happen. -#-------------------------------------------------------------------------------------------------- - sub print_overall_summary_script_error - { - open OVER_ALL_SUMMARY, ">>$overal_summary_file" or return ; - if(scalar @gloabl_errors) - { - print OVER_ALL_SUMMARY "

Execution Errors

\n "; - my $count = 1; - foreach $_(@gloabl_errors) - { - print OVER_ALL_SUMMARY "

$count.$_

\n"; - $count++; - } - print OVER_ALL_SUMMARY "View Error details : $results_destinationdir_log\\$unittest_log_file \n "; - } - close OVER_ALL_SUMMARY; - } - -# End of file.