sbsv2/raptor/test/smoke_suite/whatcomp.py
branchwip
changeset 137 befd82d9c937
parent 124 e898967975af
child 170 d1af983e283d
equal deleted inserted replaced
136:d84e89d4dde4 137:befd82d9c937
    21 def run():
    21 def run():
    22 	t = SmokeTest()
    22 	t = SmokeTest()
    23 	t.usebash = True
    23 	t.usebash = True
    24 	result = SmokeTest.PASS
    24 	result = SmokeTest.PASS
    25 
    25 
    26 	abs_epocroot = os.path.abspath(os.environ["EPOCROOT"]).replace("\\","/")
    26 	abs_epocroot = os.path.abspath(os.environ["EPOCROOT"])
    27 	cwd = os.getcwd().replace("\\","/")
    27 	cwd = os.getcwd().replace("\\","/")
    28 
    28 
    29 	relative_epocroot = os.path.relpath(abs_epocroot,cwd).replace("\\","/")
    29 	relative_epocroot = os.path.relpath(abs_epocroot.replace("\\","/"),cwd)
    30 
    30 
    31 	
    31 	
    32 
       
    33 	description = """This tests the whatcomp filter.  As a byproduct it uses (and thus smoke-tests) sbs_filter.py"""
    32 	description = """This tests the whatcomp filter.  As a byproduct it uses (and thus smoke-tests) sbs_filter.py"""
    34 	command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c %s -m ${SBSMAKEFILE} -f ${SBSLOGFILE} what  && " + \
    33 	command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c %s -m ${SBSMAKEFILE} -f ${SBSLOGFILE} what  && " + \
    35 		  "EPOCROOT=%s sbs_filter --filters FilterWhatComp < ${SBSLOGFILE} &&" % relative_epocroot + \
    34 		  "EPOCROOT='%s' sbs_filter --filters FilterWhatComp < ${SBSLOGFILE} &&" % relative_epocroot + \
    36 		  "EPOCROOT=%s sbs_filter --filters FilterWhatComp < ${SBSLOGFILE}"  % abs_epocroot
    35 		  "EPOCROOT='%s' sbs_filter --filters FilterWhatComp < ${SBSLOGFILE}"  % abs_epocroot
    37 	targets = [
    36 	targets = [
    38 		]	
    37 		]	
    39 	buildtargets = [
    38 	buildtargets = [
    40 		]
    39 		]
    41 	mustmatch = [
    40 
       
    41 	mustmatch_pre = [
    42 		"-- abld -w",
    42 		"-- abld -w",
    43 		"Chdir .*/smoke_suite/test_resources/simple",
    43 		".*Chdir .*/smoke_suite/test_resources/simple.*",
    44 		relative_epocroot + "/epoc32/release/armv5/urel/test.exe",
    44 		relative_epocroot + "/epoc32/release/armv5/urel/test.exe",
    45 		relative_epocroot + "/epoc32/release/armv5/urel/test.exe.map",
    45 		relative_epocroot + "/epoc32/release/armv5/urel/test.exe.map",
    46 		abs_epocroot + "/epoc32/release/armv5/urel/test.exe",
    46 		abs_epocroot + "/epoc32/release/armv5/urel/test.exe",
    47 		abs_epocroot + "/epoc32/release/armv5/urel/test.exe.map",
    47 		abs_epocroot + "/epoc32/release/armv5/urel/test.exe.map",
    48 	] 
    48 	] 
       
    49 	
       
    50 	if os.sep == '\\':
       
    51 		mustmatch = [ i.replace("\\", "\\\\" ).replace("/","\\\\") for i in mustmatch_pre ]
       
    52 	else:
       
    53 		mustmatch = mustmatch_pre
       
    54 
    49 	mustnotmatch = [
    55 	mustnotmatch = [
    50 	"error: no (CHECK|WHAT) information found"
    56 	"error: no (CHECK|WHAT) information found"
    51 	]
    57 	]
    52 	warnings = 0
    58 	warnings = 0
    53 	
    59