sbsv2/raptor/test/smoke_suite/parallel_parsing.py
author Daniel Jacobs <daniel.jacobs@nokia.com>
Thu, 01 Apr 2010 15:50:33 +0100
branchwip
changeset 450 63f3bc391c14
parent 22 072f869b0bc5
permissions -rw-r--r--
Fix mismatches in test names vs. file names.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
14
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     1
#
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     2
# Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     3
# All rights reserved.
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     4
# This component and the accompanying materials are made available
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     5
# under the terms of the License "Eclipse Public License v1.0"
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     6
# which accompanies this distribution, and is available
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     7
# at the URL "http://www.eclipse.org/legal/epl-v10.html".
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     8
#
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
     9
# Initial Contributors:
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    10
# Nokia Corporation - initial contribution.
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    11
#
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    12
# Contributors:
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    13
#
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    14
# Description: 
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    15
#
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    16
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    17
from raptor_tests import SmokeTest
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    18
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    19
def run():
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    20
	t = SmokeTest()
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    21
	t.usebash = True
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    22
	result = SmokeTest.PASS
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    23
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    24
	description = """This test covers parallel parsing."""
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    25
	command = "cd $(SBS_HOME)/test/smoke_suite/test_resources/pp/ && sbs --command=$(SBS_HOME)/test/smoke_suite/test_resources/pp/ppbldinf_commandfile -c armv5 -c winscw --pp=on --noexport -m ${SBSMAKEFILE} -f - | grep recipe "
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    26
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    27
	mmpcount = 10 # how many mmps in this parallel parsing test
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    28
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    29
	
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    30
	target_templ = [
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    31
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe",
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    32
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe.map",
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    33
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe",
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    34
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe.map",
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    35
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe.sym",
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    36
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe.sym"
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    37
	]
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    38
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    39
	targets = []
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    40
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    41
	# Build up target list for 10 similar executables
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    42
	for num in range(1,mmpcount):
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    43
		for atarget in target_templ:
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    44
			targets.append(atarget.replace('pp#','pp'+ str(num)))
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    45
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    46
	mustmatch = [
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    47
		".*<recipe .*name='makefile_generation.*",
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    48
	]
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    49
	mustnotmatch = [
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    50
		".*<recipe .*name='makefile_generation_export.*",
15
9d01f1c36469 Fix tests as review comments.
tnmurphy@4GBL06592.nokia.com
parents: 14
diff changeset
    51
		".*<error[^><]*>.*"
14
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    52
	]
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    53
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    54
	warnings = 0
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    55
		
22
072f869b0bc5 Catch up to wip branch
timothy.murphy@nokia.com
parents: 15
diff changeset
    56
	t.id = "104"
450
63f3bc391c14 Fix mismatches in test names vs. file names.
Daniel Jacobs <daniel.jacobs@nokia.com>
parents: 22
diff changeset
    57
	t.name = "parallel_parsing"
14
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    58
	t.description = description
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    59
	t.command = command 
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    60
	t.targets = targets
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    61
	t.mustmatch = mustmatch
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    62
	t.mustnotmatch = mustnotmatch
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    63
	t.warnings = warnings
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    64
	t.run()
45cdac6e50c6 --noexport option
tnmurphy@4GBL06592.nokia.com
parents:
diff changeset
    65
	return t