homescreenapp/hshomescreenclientplugin/tsrc/t_hshomescreenclientplugin/decision_cov_emulator.pl
changeset 90 3ac3aaebaee5
parent 86 e4f038c420f7
child 94 6364b99b9e27
child 95 32e56106abf2
equal deleted inserted replaced
86:e4f038c420f7 90:3ac3aaebaee5
     1 #
       
     2 # Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 # All rights reserved.
       
     4 # This component and the accompanying materials are made available
       
     5 # under the terms of "Eclipse Public License v1.0"
       
     6 # which accompanies this distribution, and is available
       
     7 # at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 #
       
     9 # Initial Contributors:
       
    10 # Nokia Corporation - initial contribution.
       
    11 #
       
    12 # Contributors:
       
    13 #
       
    14 # Description: Script for running branch coverage test
       
    15 #
       
    16 
       
    17 #USAGE:
       
    18 #    Usage: decision_cov.pl [-make=command]
       
    19 #    -make=instrument || run || ctcpost
       
    20 
       
    21 # import module
       
    22 use Getopt::Long;
       
    23 
       
    24 # read options
       
    25 my $make = "all";
       
    26 my $success = GetOptions ("make=s"   => \$make);
       
    27 
       
    28 if($make) {
       
    29     if (($make eq "instrument") || ($make eq "all")) {
       
    30         system("del mon.sym");
       
    31         system("del mon.dat");
       
    32         system("del profile.txt");
       
    33         system("rmdir /s /q CTCFUNCTION");
       
    34         system("rmdir /s /q CTCDECISION");
       
    35 		system("call qmake -config coverage");
       
    36 		system("call sbs -c winscw_udeb.test");
       
    37 		system("call sbs -c winscw_udeb.test clean");
       
    38 		system("call sbs -c winscw_udeb clean");
       
    39 		system("call sbs -c winscw_udeb");
       
    40 		system("call ctcwrap -i fd -2comp -no-conf-check -C EXCLUDE=* -C NO_EXCLUDE=./../../src/* sbs -c winscw_udeb.test");
       
    41 	}
       
    42     if (($make eq "run") || ($make eq "all")) {
       
    43 		system("call \\epoc32\\release\\winscw\\udeb\\t_hshomescreenclientplugin.exe -o c:\\t_hshomescreenclientplugin.log");
       
    44 	}
       
    45 	if (($make eq "ctcpost") || ($make eq "all")) {
       
    46 		system("call ctcpost -ff -p profile.txt");
       
    47 		system("call ctc2html -nsb -i profile.txt -o CTCFUNCTION");
       
    48 		system("call del profile.txt");
       
    49 		system("call ctcpost -fd -p profile.txt");
       
    50 		system("call ctc2html -nsb -i profile.txt -o CTCDECISION");
       
    51 		system("call del profile.txt");
       
    52 	}
       
    53 }	
       
    54 print "END.\n";