sbsv2/raptor/test/smoke_suite/timing.py
changeset 591 22486c9c7b15
equal deleted inserted replaced
590:360bd6b35136 591:22486c9c7b15
       
     1 #
       
     2 # Copyright (c) 2010 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 the License "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: 
       
    15 #
       
    16 
       
    17 from raptor_tests import SmokeTest
       
    18 
       
    19 def run():
       
    20 	t = SmokeTest()
       
    21 	t.usebash = True
       
    22 	
       
    23 	t.description = "Test that a timing log is created and contains total parse and build durations"
       
    24 
       
    25 	t.id = "0103b"
       
    26 	t.name = "timing_on"
       
    27 	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf" + \
       
    28 			" --filters=FilterLogfile,FilterTiming -f ${SBSLOGFILE} && " + \
       
    29 			"grep progress:duration ${SBSLOGFILE}.timings"
       
    30 	t.mustmatch = [
       
    31 			"^<progress:duration object_type='layer' task='parse' key='.*' duration='\d+.\d+' />$",
       
    32 			"^<progress:duration object_type='layer' task='build' key='.*' duration='\d+.\d+' />$",
       
    33 			"^<progress:duration object_type='all' task='all' key='all' duration='\d+.\d+' />$"
       
    34 			]
       
    35 	t.mustnotmatch = []
       
    36 	t.run()
       
    37 
       
    38 
       
    39 	t.id = "103"
       
    40 	t.name = "timing"
       
    41 	t.print_result()
       
    42 	
       
    43 	return t
       
    44