Exemplo n.º 1
0
def run():
	t = AntiTargetSmokeTest()
	t.name = "armv5_testcode"
	t.command = "sbs -b smoke_suite/test_resources/simple_test/bld.inf -c " + \
			"armv5.test -f - "
	
	# Don't allow -f to be appended
	t.logfileOption = lambda :""
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/simple_test_auto.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/simple_test_manual.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/simple_test_auto.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/simple_test_manual.exe",
		"$(EPOCROOT)/epoc32/include/testexportheader.h",
		"$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.auto.bat",
		"$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.manual.bat"
		]
	t.mustmatch = [".*/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.auto.bat</build>.*"]
	t.run()

	# Check armv5.auto.bat doesn't get generated with -p option 
	t.name = "armv5_testcode_partial"	
	t.command = "sbs -b smoke_suite/test_resources/simple_test/bld.inf " \
			+ "-c armv5.test -p simple_test_auto.mmp" 
	del t.logfileOption
	t.targets = []
	t.antitargets = [
		"$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.auto.bat"
		]
	t.mustmatch = []
	t.mustnotmatch = []
	t.warnings = 0
	t.run()	

	return t
def run():
	t = AntiTargetSmokeTest()
	t.usebash = True

	t.name = "plugin_armv5_winscw_freeze"
	t.description = """Builds several ECOM plugins, with and without explicit DEFFILE statements, confirming
		the correct FREEZE behaviour in each case.  The correct behaviour for a PLUGIN/PLUGIN3 is
		indicative of all TARGETTYPEs where the build system defines known exports: FREEZE should do nothing
		unless an explicit DEFFILE statement is present in the .mmp file.
		Also confirms:
		i) default UID2 settings for PLUGIN3 TARGETTYPEs and default resource generation locations
		   for both PLUGIN and PLUGIN3
		ii) non-generation of an import library where EXPORTUNFROZEN is used without a DEFFILE statement"""
	
	t.command = """
		sbs -b smoke_suite/test_resources/simple_plugin/bld.inf -c armv5_urel -c winscw_urel CLEAN > /dev/null &&
		sbs -f- -b smoke_suite/test_resources/simple_plugin/bld.inf -c armv5_urel -c winscw_urel &&
		sbs -b smoke_suite/test_resources/simple_plugin/bld.inf -c armv5_urel -c winscw_urel FREEZE -m ${SBSMAKEFILE} -f ${SBSLOGFILE}"""

	t.targets = [
		"smoke_suite/test_resources/simple_plugin/bwins/plugin2u.def",
		"smoke_suite/test_resources/simple_plugin/eabi/plugin2u.def",
		"$(EPOCROOT)/epoc32/data/z/resource/plugins/plugin.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/plugins/plugin.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/plugins/plugin.rsc",
		"$(EPOCROOT)/epoc32/data/z/resource/plugins/plugin3.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/plugins/plugin3.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/plugins/plugin3.rsc"	
		]
	
	t.antitargets = [
		"smoke_suite/test_resources/simple_plugin/bwins/pluginu.def",
		"smoke_suite/test_resources/simple_plugin/eabi/pluginu.def",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/plugin4.lib",
		"$(EPOCROOT)/epoc32/release/armv5/lib/plugin4.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/plugin4{000a0000}.dso"
		]
	
	t.mustmatch = [
		".*EFREEZE: Appending 3 New Export\(s\) to .*/test/smoke_suite/test_resources/simple_plugin/eabi/plugin2u.def.*",
		".*EFREEZE: Appending 1 New Export\(s\) to .*/test/smoke_suite/test_resources/simple_plugin/bwins/plugin2u.def.*",
		".*__EMULATOR_IMAGE_HEADER2\(0x10000079,0x10009D93,0x00000000.*",
		".*elf2e32.*--targettype=PLUGIN3.*--output=.*plugin3.dll.*--uid2=0x10009D93.*"
		
		]

	t.mustnotmatch = [
		".*EFREEZE: .*/test/smoke_suite/test_resources/simple_plugin/eabi/pluginu.def.*",
		".*EFREEZE: .*/test/smoke_suite/test_resources/simple_plugin/bwins/pluginu.def.*"
		]
	
	t.warnings = 4	
	t.run()
	return t
Exemplo n.º 3
0
def run():
    t = AntiTargetSmokeTest()
    t.usebash = True

    t.name = "plugin_armv5_winscw_freeze"
    t.description = """Builds several ECOM plugins, with and without explicit DEFFILE statements, confirming
		the correct FREEZE behaviour in each case.  The correct behaviour for a PLUGIN/PLUGIN3 is
		indicative of all TARGETTYPEs where the build system defines known exports: FREEZE should do nothing
		unless an explicit DEFFILE statement is present in the .mmp file.
		Also confirms:
		i) default UID2 settings for PLUGIN3 TARGETTYPEs and default resource generation locations
		   for both PLUGIN and PLUGIN3
		ii) non-generation of an import library where EXPORTUNFROZEN is used without a DEFFILE statement"""

    t.command = """
		sbs -b smoke_suite/test_resources/simple_plugin/bld.inf -c armv5_urel -c winscw_urel CLEAN > /dev/null &&
		sbs -f- -b smoke_suite/test_resources/simple_plugin/bld.inf -c armv5_urel -c winscw_urel &&
		sbs -b smoke_suite/test_resources/simple_plugin/bld.inf -c armv5_urel -c winscw_urel FREEZE -m ${SBSMAKEFILE} -f ${SBSLOGFILE}"""

    t.targets = [
        "smoke_suite/test_resources/simple_plugin/bwins/plugin2u.def",
        "smoke_suite/test_resources/simple_plugin/eabi/plugin2u.def",
        "$(EPOCROOT)/epoc32/data/z/resource/plugins/plugin.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/plugins/plugin.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/plugins/plugin.rsc",
        "$(EPOCROOT)/epoc32/data/z/resource/plugins/plugin3.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/plugins/plugin3.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/plugins/plugin3.rsc"
    ]

    t.antitargets = [
        "smoke_suite/test_resources/simple_plugin/bwins/pluginu.def",
        "smoke_suite/test_resources/simple_plugin/eabi/pluginu.def",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/plugin4.lib",
        "$(EPOCROOT)/epoc32/release/armv5/lib/plugin4.dso",
        "$(EPOCROOT)/epoc32/release/armv5/lib/plugin4{000a0000}.dso"
    ]

    t.mustmatch = [
        ".*EFREEZE: Appending 3 New Export\(s\) to .*/test/smoke_suite/test_resources/simple_plugin/eabi/plugin2u.def.*",
        ".*EFREEZE: Appending 1 New Export\(s\) to .*/test/smoke_suite/test_resources/simple_plugin/bwins/plugin2u.def.*",
        ".*__EMULATOR_IMAGE_HEADER2\(0x10000079,0x10009D93,0x00000000.*",
        ".*elf2e32.*--targettype=PLUGIN3.*--output=.*plugin3.dll.*--uid2=0x10009D93.*"
    ]

    t.mustnotmatch = [
        ".*EFREEZE: .*/test/smoke_suite/test_resources/simple_plugin/eabi/pluginu.def.*",
        ".*EFREEZE: .*/test/smoke_suite/test_resources/simple_plugin/bwins/pluginu.def.*"
    ]

    t.warnings = 4
    t.run()
    return t
Exemplo n.º 4
0
def run():
    t = AntiTargetSmokeTest()
    t.name = "armv5_testcode"
    t.command = "sbs -b smoke_suite/test_resources/simple_test/bld.inf -c " + \
      "armv5.test -f - "

    # Don't allow -f to be appended
    t.logfileOption = lambda: ""
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/urel/simple_test_auto.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/simple_test_manual.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/simple_test_auto.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/simple_test_manual.exe",
        "$(EPOCROOT)/epoc32/include/testexportheader.h",
        "$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.auto.bat",
        "$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.manual.bat"
    ]
    t.mustmatch = [
        ".*/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.auto.bat</build>.*"
    ]
    t.run()

    # Check armv5.auto.bat doesn't get generated with -p option
    t.name = "armv5_testcode_partial"
    t.command = "sbs -b smoke_suite/test_resources/simple_test/bld.inf " \
      + "-c armv5.test -p simple_test_auto.mmp"
    del t.logfileOption
    t.targets = []
    t.antitargets = [
        "$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv5.auto.bat"
    ]
    t.mustmatch = []
    t.mustnotmatch = []
    t.warnings = 0
    t.run()

    return t
Exemplo n.º 5
0
def run():
	t = AntiTargetSmokeTest()
	t.usebash = True
	
	genericTargets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/dependency.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/dependency.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/dependency.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/dependency.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/dependency.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/dependency.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/dependency.exe",
		"$(EPOCROOT)/epoc32/include/dependency.rsg",
		"$(EPOCROOT)/epoc32/data/z/resource/apps/dependency.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/dependency.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/dependency.rsc",
		"$(EPOCROOT)/epoc32/include/main.rsg",
		"$(EPOCROOT)/epoc32/data/z/resource/apps/main.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/main.rsc",
		"$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/main.rsc"
		]
	windowsTargets = [
		"$(EPOCROOT)/epoc32/release/tools2/rel/dependency.exe",
		"$(EPOCROOT)/epoc32/tools/dependency.exe"
	]
	linuxTargets = [
		"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/rel/dependency",
		"$(EPOCROOT)/epoc32/tools/dependency"
	]

	# Set general host platform specifics from first test run, but assume Windows initially
	hostPlatform = "windows"
	hostPlatformTargets = genericTargets + windowsTargets
	hostPlatformOffset = ""

	t.name = "baseline_build"
	t.description = "Build a component with source and resource files that are dependent on header files exported in the build"
	t.command = """
		cp smoke_suite/test_resources/dependencies/src/dependency1.cpp smoke_suite/test_resources/dependencies/dependency.cpp
		cp smoke_suite/test_resources/dependencies/src/dependency1.rss smoke_suite/test_resources/dependencies/dependency.rss
		sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""		
	t.mustnotmatch = [
		"<warning>Missing dependency detected: .*</warning>"
	]
	t.targets = hostPlatformTargets
	t.run(hostPlatform)
	if t.result == AntiTargetSmokeTest.SKIP:
		hostPlatform = "linux"
		hostPlatformTargets = genericTargets + linuxTargets
		hostPlatformOffset = "$(HOSTPLATFORM32_DIR)/"
		t.targets = hostPlatformTargets
		t.run(hostPlatform)
	
	# Ensure we don't clean up from the previous build in the following two tests
	t.targets = []
	
	# Core expected outcome for the following two tests
	t.mustmatch = [
		".*recipe name='compile' target='.*dependency\.o'",
		".*recipe name='win32compile2object' target='.*dependency\.o'",
		".*recipe name='compile2object' target='.*dependency\.o'",
		".*recipe name='resourcecompile' target='.*dependency\.rsc'"
	]
	t.countmatch = [
		[".*recipe name='compile'", 2],
		[".*recipe name='win32compile2object'", 2],
		[".*recipe name='compile2object'", 1],
		[".*recipe name='resourcecompile", 2]
	]

	
	t.name ="touched_header_dependencies"
	t.description = "Touch the exported header files and check that only the related source and resource files are re-built"
	t.command = """
		sleep 1
		touch $(EPOCROOT)/epoc32/include/dependency.h
		touch $(EPOCROOT)/epoc32/include/dependency.rh
		sbs -f- -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
	t.run()

	
	t.name ="redundant_header_dependencies"
	t.description = """
		Build the component again, but manipulate it so that (a) it no longer has a dependency on the exported header files and
		(b) the header files have been removed and (c) the header files are no longer exported.  Check that only the related source
		and resource files are re-built"""
	t.command = """
		cp smoke_suite/test_resources/dependencies/src/dependency2.cpp smoke_suite/test_resources/dependencies/dependency.cpp
		cp smoke_suite/test_resources/dependencies/src/dependency2.rss smoke_suite/test_resources/dependencies/dependency.rss
		rm -rf $(EPOCROOT)/epoc32/include/dependency.h
		rm -rf $(EPOCROOT)/epoc32/include/dependency.rh
		sbs -f- --noexport -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
	t.mustnotmatch = []
	# Note that the resource build does not exhibit a missing dependency as its dependency files are generated in a separate stage where
	# the target file isn't actually a target of that stage
	t.mustmatch.extend([
		"<warning>Missing dependency detected: .*/epoc32/include/dependency.h</warning>"
		])
	t.warnings = 1
	t.run()
	

	t.name ="invalid_dependency_files"
	t.description = "Invalidate dependency files, then make sure we can clean and re-build successfully"
	buildLocation = "$(EPOCROOT)/epoc32/build/" + BldInfFile.outputPathFragment('smoke_suite/test_resources/dependencies/bld.inf') + "/dependency_"
        # use one long bash command so that we can capture 
	# the output in a way that isn't messed up with all the ordering confused.
	t.command = " echo \"making directory for logfile ${{SBSLOGFILE}}\" ; mkdir -p `dirname ${{SBSLOGFILE}} 2>/dev/null` ; {{ sleep 1 ; set -x ; \
touch smoke_suite/test_resources/dependencies/dependency.cpp; \
echo INVALIDATE_ARMV5_DEPENDENCY_FILE >> {0}/armv5/urel/dependency.o.d ; \
echo INVALIDATE_WINSCW_DEPENDENCY_FILE >> {0}/winscw/urel/dependency.o.d ;\
echo INVALIDATE_TOOLS2_DEPENDENCY_FILE >> {0}/dependency_exe/tools2/rel/{1}/dependency.o.d ;\
echo INVALIDATE_RESOURCE_DEPENDENCY_FILE >> {0}/dependency__resource_apps.rsc.d ;\
sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel ;\
sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel clean ;\
sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel ; }} > ${{SBSLOGFILE}} 2>&1; grep 'missing separator' ${{SBSLOGFILE}} ".format(buildLocation, hostPlatformOffset)
	# We expect an error from the first build due to the deliberate dependency file corruption
	t.mustmatch = [
		".*dependency.o.d:[0-9]+: \*\*\* missing separator"
		]
	t.countmatch = []
	t.warnings = 0
	t.errors = 0 
	t.targets = hostPlatformTargets
	t.run(hostPlatform)


	t.name ="no_depend_include"
	t.description = "Invalidate dependency files in order to confirm they aren't processed when --no-depend-include is used"
	buildLocation = "$(EPOCROOT)/epoc32/build/" + BldInfFile.outputPathFragment('smoke_suite/test_resources/dependencies/bld.inf') + "/dependency_"
	t.command = """
		sleep 1
		touch smoke_suite/test_resources/dependencies/dependency.cpp
		echo INVALIDATE_ARMV5_DEPENDENCY_FILE >> """+buildLocation+"""/armv5/urel/dependency.o.d
		echo INVALIDATE_WINSCW_DEPENDENCY_FILE >> """+buildLocation+"""/winscw/urel/dependency.o.d
		echo INVALIDATE_TOOLS2_DEPENDENCY_FILE >> """+buildLocation+"""/dependency_exe/tools2/rel/"""+hostPlatformOffset+"""dependency.o.d
		sbs --no-depend-include -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
	t.mustmatch = []
	t.errors = 0		
	t.targets = hostPlatformTargets
	t.run(hostPlatform)


	t.name ="no_depend_generate"
	t.description = "Invalidate and remove dependency files in order to confirm they are neither included nor re-generated when --no-depend-generate is used"
	buildLocation = "$(EPOCROOT)/epoc32/build/" + BldInfFile.outputPathFragment('smoke_suite/test_resources/dependencies/bld.inf') + "/dependency_"
	t.command = """
		sleep 1
		touch smoke_suite/test_resources/dependencies/dependency.cpp
		touch smoke_suite/test_resources/dependencies/main.cpp
		echo INVALIDATE_ARMV5_DEPENDENCY_FILE >> """+buildLocation+"""/armv5/urel/dependency.o.d
		echo INVALIDATE_WINSCW_DEPENDENCY_FILE >> """+buildLocation+"""/winscw/urel/dependency.o.d
		echo INVALIDATE_TOOLS2_DEPENDENCY_FILE >> """+buildLocation+"""/dependency_exe/tools2/rel/"""+hostPlatformOffset+"""dependency.o.d
		sbs --no-depend-generate -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
	t.antitargets = [
		buildLocation+"/armv5/urel/main.o.d",
		buildLocation+"/armv5/udeb/main.o.d",
		buildLocation+"/winscw/urel/main.o.d",
		buildLocation+"/winscw/udeb/main.o.d",
		buildLocation+"/dependency_exe/tools2/rel/"+hostPlatformOffset+"main.o.d"
		]
	t.targets = hostPlatformTargets
	t.run(hostPlatform)
	
	# clean-up
	os.remove("smoke_suite/test_resources/dependencies/dependency.cpp")
	os.remove("smoke_suite/test_resources/dependencies/dependency.rss")

	t.name = "dependencies"
	t.print_result()
	return t
def run():
	# 102a - 102b Test running trace compiler on one mmp with different source files controlled macros. 
	t = AntiTargetSmokeTest()
	t.description = "Testcases (ID 102a - 102c) test trace compiler running with variants and macros"
	
	# 1st time build includes var_source1 and var_source2 for variant_source.mmp
	t.id = "102a"
	t.name = "TC_variant_source_var1"
	t.command = "sbs -b smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf -c default.tc_var1" + \
			" --configpath=test/smoke_suite/test_resources/tracecompiler/variant_source"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/variant_source.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/variant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/variant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/variant_source.exe",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/inv_sourceTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source1Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source2Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/fixed_id.definitions",
		"$(EPOCROOT)/epoc32/ost_dictionaries/invariant_source_0x10000002_Dictionary.xml",
		"$(EPOCROOT)/epoc32/ost_dictionaries/variant_source_0x10000003_Dictionary.xml",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/invariant_source_0x10000002_TraceDefinitions.h",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/variant_source_0x10000003_TraceDefinitions.h"
		]
	t.addbuildtargets('smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf', [
		"invariant_source_/armv5/udeb/inv_source.o",
		"invariant_source_/armv5/udeb/inv_source.o.d",
		"invariant_source_/armv5/urel/inv_source.o",
		"invariant_source_/armv5/urel/inv_source.o.d",
		"invariant_source_/winscw/udeb/inv_source.o",
		"invariant_source_/winscw/udeb/inv_source.o.d",
		"invariant_source_/winscw/urel/inv_source.o",
		"invariant_source_/winscw/urel/inv_source.o.d",
		"invariant_source_/tracecompile_invariant_source_exe_10000002.done",
		"variant_source_/armv5/udeb/var_source1.o",
		"variant_source_/armv5/udeb/var_source1.o.d",
		"variant_source_/armv5/udeb/var_source2.o",
		"variant_source_/armv5/udeb/var_source2.o.d",
		"variant_source_/armv5/urel/var_source1.o",
		"variant_source_/armv5/urel/var_source1.o.d",
		"variant_source_/armv5/urel/var_source2.o",
		"variant_source_/armv5/urel/var_source2.o.d",
		"variant_source_/winscw/udeb/var_source1.o",
		"variant_source_/winscw/udeb/var_source1.o.d",
		"variant_source_/winscw/udeb/var_source2.o",
		"variant_source_/winscw/udeb/var_source2.o.d",
		"variant_source_/winscw/urel/var_source1.o",
		"variant_source_/winscw/urel/var_source1.o.d",
		"variant_source_/winscw/urel/var_source2.o",
		"variant_source_/winscw/urel/var_source2.o.d",
		"variant_source_/tracecompile_variant_source_exe_10000003.done"
	])
	t.antitargets = [
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source3Traces.h"
		]
	t.addbuildantitargets('smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf', [
		"variant_source_/armv5/udeb/var_source3.o",
		"variant_source_/armv5/urel/var_source3.o",
		"variant_source_/winscw/udeb/var_source3.o",
		"variant_source_/winscw/urel/var_source3.o"
	])
	t.run()

	# 2nd time build includes var_source1 and var_source3 for variant_source.mmp
	t = SmokeTest()
	t.id = "102b"
	t.name = "TC_variant_source_var2"
	t.command = "sbs -b smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf -c default.tc_var2" + \
			" --configpath=test/smoke_suite/test_resources/tracecompiler/variant_source"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/variant_source.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/variant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/variant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/invariant_source.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/variant_source.exe",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/inv_sourceTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source1Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source2Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source3Traces.h",
		"$(EPOCROOT)/epoc32/ost_dictionaries/invariant_source_0x10000002_Dictionary.xml",
		"$(EPOCROOT)/epoc32/ost_dictionaries/variant_source_0x10000003_Dictionary.xml",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/invariant_source_0x10000002_TraceDefinitions.h",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/variant_source_0x10000003_TraceDefinitions.h"
		]
	t.addbuildtargets('smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf', [
		"invariant_source_/armv5/udeb/inv_source.o",
		"invariant_source_/armv5/udeb/inv_source.o.d",
		"invariant_source_/armv5/urel/inv_source.o",
		"invariant_source_/armv5/urel/inv_source.o.d",
		"invariant_source_/winscw/udeb/inv_source.o",
		"invariant_source_/winscw/udeb/inv_source.o.d",
		"invariant_source_/winscw/urel/inv_source.o",
		"invariant_source_/winscw/urel/inv_source.o.d",
		"invariant_source_/tracecompile_invariant_source_exe_10000002.done",
		"variant_source_/armv5/udeb/var_source1.o",
		"variant_source_/armv5/udeb/var_source1.o.d",
		"variant_source_/armv5/udeb/var_source3.o",
		"variant_source_/armv5/udeb/var_source3.o.d",
		"variant_source_/armv5/urel/var_source1.o",
		"variant_source_/armv5/urel/var_source1.o.d",
		"variant_source_/armv5/urel/var_source3.o",
		"variant_source_/armv5/urel/var_source3.o.d",
		"variant_source_/winscw/udeb/var_source1.o",
		"variant_source_/winscw/udeb/var_source1.o.d",
		"variant_source_/winscw/udeb/var_source3.o",
		"variant_source_/winscw/udeb/var_source3.o.d",
		"variant_source_/winscw/urel/var_source1.o",
		"variant_source_/winscw/urel/var_source1.o.d",
		"variant_source_/winscw/urel/var_source3.o",
		"variant_source_/winscw/urel/var_source3.o.d",
		"variant_source_/tracecompile_variant_source_exe_10000003.done"
	])
	t.run()

	# Build multiple variants together, which involves different source files in one mmp
	# Raptor only call trace compiler once no matter how many variants
	# In this example, ".phone" 1 2 3 involve tc_a b c respectively, and all involve tc_main
	t = SmokeTest()
	t.id = "102c"
	t.name = "TC_multiple_variants"
	t.command = "sbs -b smoke_suite/test_resources/tracecompiler/multiple_variants/group/bld.inf" + \
			" -c armv5.phone1 -c armv5.phone2 -c armv5.phone3" + \
			" --configpath=test/smoke_suite/test_resources/tracecompiler/multiple_variants"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5.phone1/udeb/tc_variants.exe",
		"$(EPOCROOT)/epoc32/release/armv5.phone1/urel/tc_variants.exe",
		"$(EPOCROOT)/epoc32/release/armv5.phone2/udeb/tc_variants.exe",
		"$(EPOCROOT)/epoc32/release/armv5.phone2/urel/tc_variants.exe",
		"$(EPOCROOT)/epoc32/release/armv5.phone3/udeb/tc_variants.exe",
		"$(EPOCROOT)/epoc32/release/armv5.phone3/urel/tc_variants.exe",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_mainTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_aTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_bTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_cTraces.h",
		"$(EPOCROOT)/epoc32/ost_dictionaries/tc_variants_0x10000004_Dictionary.xml",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/tc_variants_0x10000004_TraceDefinitions.h"
		]
	t.addbuildtargets('smoke_suite/test_resources/tracecompiler/multiple_variants/group/bld.inf', [
		"tc_variants_/armv5.phone1/udeb/tc_main.o",
		"tc_variants_/armv5.phone1/udeb/tc_a.o",
		"tc_variants_/armv5.phone1/urel/tc_main.o",
		"tc_variants_/armv5.phone1/urel/tc_a.o",
		"tc_variants_/armv5.phone2/udeb/tc_main.o",
		"tc_variants_/armv5.phone2/udeb/tc_b.o",
		"tc_variants_/armv5.phone2/urel/tc_main.o",
		"tc_variants_/armv5.phone2/urel/tc_b.o",
		"tc_variants_/armv5.phone3/udeb/tc_main.o",
		"tc_variants_/armv5.phone3/udeb/tc_c.o",
		"tc_variants_/armv5.phone3/urel/tc_main.o",
		"tc_variants_/armv5.phone3/urel/tc_c.o",
		"tc_variants_/tracecompile_tc_variants_exe_10000004.done"
	])	
	t.run()

	# 102d and 102e is to test a very rare situation, where one mmpfile includes 3 children mmpfiles, 
	# which are guarded by macros. They share some source file, and two share the same UID3. 
	# When build them together, Raptor should be able to distinguish them and run trace compiler 
	# on each of them. 
	t = SmokeTest()
	t.id = "102d"
	t.name = "TC_mum_children_mmps_build"
	t.command = "sbs -b smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf" + \
			" -c armv5.tc_var1 -c armv5.tc_var2 -c armv5.tc_var3" + \
			" --configpath=test/smoke_suite/test_resources/tracecompiler/mum_children_mmps"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/child1.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/child1.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/child2.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/child2.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/child3.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/child3.exe",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child1_exe/child1Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child1_exe/commonTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/child2Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/commonTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/child3Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/commonTraces.h",
		"$(EPOCROOT)/epoc32/ost_dictionaries/child1_exe_0x11100001_Dictionary.xml",
		"$(EPOCROOT)/epoc32/ost_dictionaries/child2_exe_0x11100002_Dictionary.xml",
		"$(EPOCROOT)/epoc32/ost_dictionaries/child3_exe_0x11100002_Dictionary.xml",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child1_exe_0x11100001_TraceDefinitions.h",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child2_exe_0x11100002_TraceDefinitions.h",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child3_exe_0x11100002_TraceDefinitions.h"
		]
	t.addbuildtargets('smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf', [
		"child1_/armv5/udeb/child1.o",
		"child1_/armv5/udeb/common.o",
		"child1_/armv5/urel/child1.o",
		"child1_/armv5/urel/common.o",
		"child1_/tracecompile_child1_exe_11100001.done",
		"child2_/armv5/udeb/child2.o",
		"child2_/armv5/udeb/common.o",
		"child2_/armv5/urel/child2.o",
		"child2_/armv5/urel/common.o",
		"child2_/tracecompile_child2_exe_11100002.done",
		"child3_/armv5/udeb/child3.o",
		"child3_/armv5/udeb/common.o",
		"child3_/armv5/urel/child3.o",
		"child3_/armv5/urel/common.o",
		"child3_/tracecompile_child3_exe_11100002.done"
	])
	t.warnings = 3
	t.run()

	# Clean mmp A then build mmp B and C. As common.cpp is shared by A B and C, commonTraces.h would be 
	# cleaned when cleaning mmp A. But as B and C aren't cleaned, Raptor wouldn't run trace compiler on
	# B and C, thus commonTraces.h wouldn't be generated again, so be missing for mmp B and C.
	# The solution is to use new trace path "traces/traces_<TARGET>_<TARGETTYPE>" instead of "traces" so shared 
	# source has different copy of trace headers for different projects.
	t = SmokeTest()
	t.id = "102e"
	t.name = "TC_mum_children_mmps_clean"
	t.command = "sbs -b smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf" + \
			" --configpath=test/smoke_suite/test_resources/tracecompiler/mum_children_mmps" + \
			" -c armv5.tc_var1 CLEAN && " + \
			"sbs -b smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf" + \
			" --configpath=test/smoke_suite/test_resources/tracecompiler/mum_children_mmps" + \
			" -c armv5.tc_var2 -c armv5.tc_var3"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/child2.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/child2.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/child3.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/child3.exe",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/child2Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/commonTraces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/child3Traces.h",
		"$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/commonTraces.h",
		"$(EPOCROOT)/epoc32/ost_dictionaries/child2_exe_0x11100002_Dictionary.xml",
		"$(EPOCROOT)/epoc32/ost_dictionaries/child3_exe_0x11100002_Dictionary.xml",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child2_exe_0x11100002_TraceDefinitions.h",
		"$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child3_exe_0x11100002_TraceDefinitions.h"
		]
	t.addbuildtargets('smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf', [
		"child2_/armv5/udeb/child2.o",
		"child2_/armv5/udeb/common.o",
		"child2_/armv5/urel/child2.o",
		"child2_/armv5/urel/common.o",
		"child2_/tracecompile_child2_exe_11100002.done",
		"child3_/armv5/udeb/child3.o",
		"child3_/armv5/udeb/common.o",
		"child3_/armv5/urel/child3.o",
		"child3_/armv5/urel/common.o",
		"child3_/tracecompile_child3_exe_11100002.done"
	])
	t.warnings = 3
	t.run()


	t.id = "102"
	t.name = "tracecompiler_variants"
	t.print_result()
	
	return t
Exemplo n.º 7
0
def run():

	t = AntiTargetSmokeTest()
	t.name = "unfrozen_savespace"

	t.command = "sbs -b smoke_suite/test_resources/unfrozen/bld.inf -k -c winscw -c armv5 CLEAN" \
				" && sbs -b smoke_suite/test_resources/unfrozen/bld.inf -c winscw.savespace -c armv5.savespace"

	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/lib/unfrozensymbols.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/unfrozensymbols{000a0000}.dso",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/lib/unfrozensymbols2.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/unfrozensymbols2{000a0000}.dso",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols2.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols2.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols2.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols3.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols3.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/unfrozensymbols3.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_unfrozen.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_unfrozen.exe.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_unfrozen.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/unfrozensymbols.dll",
		"$(EPOCROOT)/epoc32/release/winscw/urel/unfrozensymbols.dll.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/unfrozensymbols2.dll",
		"$(EPOCROOT)/epoc32/release/winscw/urel/unfrozensymbols2.dll.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test_unfrozen.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test_unfrozen.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols2.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols2.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols2.dll.map",	
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols3.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols3.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/unfrozensymbols3.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_unfrozen.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_unfrozen.exe.sym",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_unfrozen.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/unfrozensymbols.dll",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/unfrozensymbols.lib",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/unfrozensymbols2.dll",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/unfrozensymbols2.lib",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/unfrozensymbols3.dll",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/test_unfrozen.exe"
		]

	t.antitargets = []

	t.addbuildantitargets('smoke_suite/test_resources/unfrozen/bld.inf', [
		"test_unfrozen_/armv5/udeb",
		"test_unfrozen_/armv5/urel",
		"test_unfrozen_/winscw/udeb",
		"test_unfrozen_/winscw/urel"
		# TODO: Add these anti targets once we figure out how to actually delete
		# them.
		# "unfrozensymbols2_dll/armv5/udeb",
		# "unfrozensymbols2_dll/armv5/urel",
		# "unfrozensymbols2_dll/winscw/udeb",
		# "unfrozensymbols2_dll/winscw/urel",
		# "unfrozensymbols_dll/armv5/udeb",
		# "unfrozensymbols_dll/armv5/urel",
		# "unfrozensymbols_dll/winscw/udeb",
		# "unfrozensymbols_dll/winscw/urel"
		] )

	t.countmatch = [
			[".*Elf2e32: Warning: New Symbol .* found, export\(s\) not yet Frozen.*", 26],
			[".*\.def\(\d\) : .*@\d.*", 18]
		]

	t.warnings = 8
	t.run()
	return t
Exemplo n.º 8
0
def run():
	t = AntiTargetSmokeTest()
	t.description = """
		Tests the creation and content of .iby romfiles generated for the armv5.test
		configuration. Also tests for creation of relevant test batch files.
		"""	
	t.usebash = True
	# Don't allow -m or -f to be appended
	t.logfileOption = lambda :""
	t.makefileOption = lambda :""

	
	# Check correct .iby and batch files are generated
	t.name = "romfile_general"	
	t.command = "sbs -b $(EPOCROOT)/src/ongoing/group/romfile/other_name.inf " \
			+ "-c armv5.test ROMFILE -m ${SBSMAKEFILE} -f ${SBSLOGFILE}"
	
	t.targets = [
		"$(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5test.iby",
		"$(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5testn.iby",
		"$(EPOCROOT)/epoc32/data/z/test/src_ongoing_romfile/armv5.auto.bat",
		"$(EPOCROOT)/epoc32/data/z/test/src_ongoing_romfile/armv5.manual.bat"
		]
	t.warnings = 0 if t.onWindows else 2
	t.run()
	
	t.name = "romfile_content_exsymbian"	
	t.command = "cat $(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5test.iby"
	t.mustmatch = [
		# The comment that is put at the start of the file.
		r".*// epoc32/rom/src/ongoing/group/romfile/armv5test\.iby\n.*",

		# The batch files that are added by the build system.
		r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.auto\.bat test/romfile\.auto\.bat\n.*",
		r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.manual\.bat test/romfile\.manual\.bat\n.*",

		# Some normal files.
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_rand\.exe\s+sys/bin/t_rand\.exe\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_swapfsys\.exe\s+sys/bin/t_swapfsys\.exe\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_localtime\.exe\s+sys/bin/t_localtime\.exe\n.*",

		# Some files where the MMP file has the PAGED or UNPAGED keywords.
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_pagestress\.exe\s+sys/bin/t_pagestress\.exe\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_fsys\.exe\s+sys/bin/t_fsys\.exe\n.*",

		# Some files where the MMP file has the ROMTARGET or RAMTARGET keywords.
		r".*\ndata=/epoc32/release/##MAIN##/##BUILD##/t_prel\.dll\s+/sys/bin/t_prel\.dll attrib=r\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+sys/bin/t_sysbin\.exe\n.*",
		r".*\ndata=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+/sys/bin/t_sysbin_ram\.exe attrib=r\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+/sys/bin/t_sysbina\.exe\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+/system/programs/t_sysbinb\.exe\n.*",
		]
	if t.onWindows:
		t.mustmatch.extend([
		# romstuff.mke additions - extension makefile added, so only apply on Windows
		r".*\ndata=..\\..\\f32test\\server\\t_file.cpp\s+Test\\T_file.cpp\n.*",
		r".*\ndata=..\\..\\f32test\\server\\t_findcaptestfile.txt\s+\\sys\\bin\\t_findcaptestfile.txt\n.*"
		])
	t.mustnotmatch = [
		# Try to detect file paths that contain two or more slashes in a row,
		# without flagging C++ style comments.
		r"\w//+\w",
		
		# Confirm that no Nokia-format macros are present
		r"ABI_DIR",
		r"BUILD_DIR"
		]
	t.targets = []
	t.warnings = 0
	t.run()
	

	t.name = "romfile_content_nokia"	
	t.command = "cat $(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5testn.iby"
	t.mustmatch = [
		# The comment that is put at the start of the file.
		r".*// epoc32/rom/src/ongoing/group/romfile/armv5testn\.iby\n.*",

		# The batch files that are added by the build system.
		r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.auto\.bat test/romfile\.auto\.bat\n.*",
		r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.manual\.bat test/romfile\.manual\.bat\n.*",

		# Some normal files.
		r".*\nfile=ABI_DIR/BUILD_DIR/t_rand\.exe\s+sys/bin/t_rand\.exe\n.*",
		r".*\nfile=ABI_DIR/BUILD_DIR/t_swapfsys\.exe\s+sys/bin/t_swapfsys\.exe\n.*",
		r".*\nfile=ABI_DIR/BUILD_DIR/t_localtime\.exe\s+sys/bin/t_localtime\.exe\n.*",

		# Some files where the MMP file has the PAGED or UNPAGED keywords.
		r".*\nfile=ABI_DIR/BUILD_DIR/t_pagestress\.exe\s+sys/bin/t_pagestress\.exe\n.*",
		r".*\nfile=ABI_DIR/BUILD_DIR/t_fsys\.exe\s+sys/bin/t_fsys\.exe\n.*",

		# Some files where the MMP file has the ROMTARGET or RAMTARGET keywords.
		r".*\ndata=ABI_DIR/BUILD_DIR/t_prel\.dll\s+/sys/bin/t_prel\.dll attrib=r\n.*",
		r".*\nfile=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+sys/bin/t_sysbin\.exe\n.*",
		r".*\ndata=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+/sys/bin/t_sysbin_ram\.exe attrib=r\n.*",
		r".*\nfile=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+/sys/bin/t_sysbina\.exe\n.*",
		r".*\nfile=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+/system/programs/t_sysbinb\.exe\n.*",
		
		# append_iby.flm additions from multiple START EXTENSION blocks
		r".*\ndata=../../f32test/server/t_file.cpp\s+Test/T_file.cpp\n.*",
		r".*\ndata=../../f32test/server/t_findcaptestfile.txt\s+/sys/bin/t_findcaptestfile.txt\n.*"	
		]
	t.mustnotmatch = [
		# Try to detect file paths that contain two or more slashes in a row,
		# without flagging C++ style comments.
		r"\w//+\w",
				
		# Confirm that no exSymbian-format macros are present
		r"##MAIN##",
		r"##BUILD##"
		]
	t.targets = []
	t.warnings = 0
	t.run()
	

	t.name = "romfile_whatlog"
	t.command = "sbs -b $(EPOCROOT)/src/ongoing/group/romfile/other_name.inf " \
			+ "-c armv5.test ROMFILE -f -"
	
	t.mustmatch = [
		# Check whatlog output includes batch files and .iby file
		r".*/epoc32/rom/src/ongoing/group/romfile/armv5test.iby</build>.*",
		r".*/epoc32/rom/src/ongoing/group/romfile/armv5testn.iby</build>.*",
		r".*/epoc32/data/z/test/src_ongoing_romfile/armv5.auto.bat</build>.*",
		r".*/epoc32/data/z/test/src_ongoing_romfile/armv5.manual.bat</build>.*"
		]
	t.mustnotmatch = []
	t.warnings = 0 if t.onWindows else 2
	t.run()


	t.name = "romfile_mmp_include_twice_general"
	t.command = "sbs -b $(EPOCROOT)/src/e32test/group/bld.inf " \
	        + "-b $(EPOCROOT)/src/falcon/test/bld.inf " \
			+ "-c armv5.test ROMFILE -m ${SBSMAKEFILE} -f ${SBSLOGFILE} "
	
	t.targets = [
		"$(EPOCROOT)/epoc32/rom/src/e32test/group/armv5test.iby",
		"$(EPOCROOT)/epoc32/rom/src/e32test/group/armv5testn.iby"
		]
	t.mustmatch = []
	t.warnings = 0
	t.run()
	

	t.name = "romfile_mmp_include_twice_content_exsymbian"	
	t.command = "cat $(EPOCROOT)/epoc32/rom/src/e32test/group/armv5test.iby"	
	t.targets = []
	t.mustmatch = [
		r".*\ndevice\[MAGIC\]=/epoc32/release/##KMAIN##/##BUILD##/d_nanowait\.ldd\s+sys/bin/d_nanowait\.ldd\n.*",
		r".*\ndevice\[MAGIC\]=/epoc32/release/##KMAIN##/##BUILD##/d_pagingexample_2_post.ldd\s+sys/bin/d_pagingexample_2_post.ldd\n.*",
		]
	t.mustnotmatch = [
		# These two files are from two mmp files that included in both bld.inf
		# They shouldn't be in the ROM
		r".*/d_medch.ldd\s.*"
		r".*/d_dma.ldd\s.*"
		]
	t.warnings = 0
	t.run()

	t.name = "romfile_mmp_include_twice_content_nokia"	
	t.command = "cat $(EPOCROOT)/epoc32/rom/src/e32test/group/armv5testn.iby"	
	t.targets = []
	t.mustmatch = [
		r".*\ndevice\[VARID\]=ABI_DIR/BUILD_DIR/d_nanowait\.ldd\s+sys/bin/d_nanowait\.ldd\n.*",
		r".*\ndevice\[VARID\]=ABI_DIR/BUILD_DIR/d_pagingexample_2_post.ldd\s+sys/bin/d_pagingexample_2_post.ldd\n.*",
		]
	t.mustnotmatch = [
		# These two files are from two mmp files that included in both bld.inf
		# They shouldn't be in the ROM
		r".*/d_medch.ldd\s.*"
		r".*/d_dma.ldd\s.*"
		]
	t.warnings = 0
	t.run()

	# Check armv5.auto.bat doesn't get generated with -p option 
	t.name = "romfile_partial"	
	t.command = "sbs -b $(EPOCROOT)/src/ongoing/group/romfile/other_name.inf " \
			+ "-c armv5.test ROMFILE -p t_rcache.mmp" 
	t.antitargets = [
		"$(EPOCROOT)/epoc32/data/z/test/src_ongoing_romfile/armv5.auto.bat"
		]
	t.mustmatch = []
	t.mustnotmatch = []
	t.warnings = 0 if t.onWindows else 2
	t.run()	

	t.name = "romfile"
	t.print_result()
	return t
def run():
    # 102a - 102b Test running trace compiler on one mmp with different source files controlled macros.
    t = AntiTargetSmokeTest()
    t.description = "Testcases (ID 102a - 102c) test trace compiler running with variants and macros"

    # 1st time build includes var_source1 and var_source2 for variant_source.mmp
    t.id = "102a"
    t.name = "TC_variant_source_var1"
    t.command = "sbs -b smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf -c default.tc_var1" + \
      " --configpath=test/smoke_suite/test_resources/tracecompiler/variant_source"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/udeb/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/variant_source.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/variant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/variant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/variant_source.exe",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/inv_sourceTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source1Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source2Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/fixed_id.definitions",
        "$(EPOCROOT)/epoc32/ost_dictionaries/invariant_source_0x10000002_Dictionary.xml",
        "$(EPOCROOT)/epoc32/ost_dictionaries/variant_source_0x10000003_Dictionary.xml",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/invariant_source_0x10000002_TraceDefinitions.h",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/variant_source_0x10000003_TraceDefinitions.h"
    ]
    t.addbuildtargets(
        'smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf',
        [
            "invariant_source_/armv5/udeb/inv_source.o",
            "invariant_source_/armv5/udeb/inv_source.o.d",
            "invariant_source_/armv5/urel/inv_source.o",
            "invariant_source_/armv5/urel/inv_source.o.d",
            "invariant_source_/winscw/udeb/inv_source.o",
            "invariant_source_/winscw/udeb/inv_source.o.d",
            "invariant_source_/winscw/urel/inv_source.o",
            "invariant_source_/winscw/urel/inv_source.o.d",
            "invariant_source_/tracecompile_invariant_source_exe_10000002.done",
            "variant_source_/armv5/udeb/var_source1.o",
            "variant_source_/armv5/udeb/var_source1.o.d",
            "variant_source_/armv5/udeb/var_source2.o",
            "variant_source_/armv5/udeb/var_source2.o.d",
            "variant_source_/armv5/urel/var_source1.o",
            "variant_source_/armv5/urel/var_source1.o.d",
            "variant_source_/armv5/urel/var_source2.o",
            "variant_source_/armv5/urel/var_source2.o.d",
            "variant_source_/winscw/udeb/var_source1.o",
            "variant_source_/winscw/udeb/var_source1.o.d",
            "variant_source_/winscw/udeb/var_source2.o",
            "variant_source_/winscw/udeb/var_source2.o.d",
            "variant_source_/winscw/urel/var_source1.o",
            "variant_source_/winscw/urel/var_source1.o.d",
            "variant_source_/winscw/urel/var_source2.o",
            "variant_source_/winscw/urel/var_source2.o.d",
            "variant_source_/tracecompile_variant_source_exe_10000003.done"
        ])
    t.antitargets = [
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source3Traces.h"
    ]
    t.addbuildantitargets(
        'smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf',
        [
            "variant_source_/armv5/udeb/var_source3.o",
            "variant_source_/armv5/urel/var_source3.o",
            "variant_source_/winscw/udeb/var_source3.o",
            "variant_source_/winscw/urel/var_source3.o"
        ])
    t.run()

    # 2nd time build includes var_source1 and var_source3 for variant_source.mmp
    t = SmokeTest()
    t.id = "102b"
    t.name = "TC_variant_source_var2"
    t.command = "sbs -b smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf -c default.tc_var2" + \
      " --configpath=test/smoke_suite/test_resources/tracecompiler/variant_source"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/udeb/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/variant_source.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/variant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/variant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/invariant_source.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/variant_source.exe",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/inv_sourceTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source1Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source2Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/variant_source/traces/var_source3Traces.h",
        "$(EPOCROOT)/epoc32/ost_dictionaries/invariant_source_0x10000002_Dictionary.xml",
        "$(EPOCROOT)/epoc32/ost_dictionaries/variant_source_0x10000003_Dictionary.xml",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/invariant_source_0x10000002_TraceDefinitions.h",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/variant_source_0x10000003_TraceDefinitions.h"
    ]
    t.addbuildtargets(
        'smoke_suite/test_resources/tracecompiler/variant_source/group/bld.inf',
        [
            "invariant_source_/armv5/udeb/inv_source.o",
            "invariant_source_/armv5/udeb/inv_source.o.d",
            "invariant_source_/armv5/urel/inv_source.o",
            "invariant_source_/armv5/urel/inv_source.o.d",
            "invariant_source_/winscw/udeb/inv_source.o",
            "invariant_source_/winscw/udeb/inv_source.o.d",
            "invariant_source_/winscw/urel/inv_source.o",
            "invariant_source_/winscw/urel/inv_source.o.d",
            "invariant_source_/tracecompile_invariant_source_exe_10000002.done",
            "variant_source_/armv5/udeb/var_source1.o",
            "variant_source_/armv5/udeb/var_source1.o.d",
            "variant_source_/armv5/udeb/var_source3.o",
            "variant_source_/armv5/udeb/var_source3.o.d",
            "variant_source_/armv5/urel/var_source1.o",
            "variant_source_/armv5/urel/var_source1.o.d",
            "variant_source_/armv5/urel/var_source3.o",
            "variant_source_/armv5/urel/var_source3.o.d",
            "variant_source_/winscw/udeb/var_source1.o",
            "variant_source_/winscw/udeb/var_source1.o.d",
            "variant_source_/winscw/udeb/var_source3.o",
            "variant_source_/winscw/udeb/var_source3.o.d",
            "variant_source_/winscw/urel/var_source1.o",
            "variant_source_/winscw/urel/var_source1.o.d",
            "variant_source_/winscw/urel/var_source3.o",
            "variant_source_/winscw/urel/var_source3.o.d",
            "variant_source_/tracecompile_variant_source_exe_10000003.done"
        ])
    t.run()

    # Build multiple variants together, which involves different source files in one mmp
    # Raptor only call trace compiler once no matter how many variants
    # In this example, ".phone" 1 2 3 involve tc_a b c respectively, and all involve tc_main
    t = SmokeTest()
    t.id = "102c"
    t.name = "TC_multiple_variants"
    t.command = "sbs -b smoke_suite/test_resources/tracecompiler/multiple_variants/group/bld.inf" + \
      " -c armv5.phone1 -c armv5.phone2 -c armv5.phone3" + \
      " --configpath=test/smoke_suite/test_resources/tracecompiler/multiple_variants"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5.phone1/udeb/tc_variants.exe",
        "$(EPOCROOT)/epoc32/release/armv5.phone1/urel/tc_variants.exe",
        "$(EPOCROOT)/epoc32/release/armv5.phone2/udeb/tc_variants.exe",
        "$(EPOCROOT)/epoc32/release/armv5.phone2/urel/tc_variants.exe",
        "$(EPOCROOT)/epoc32/release/armv5.phone3/udeb/tc_variants.exe",
        "$(EPOCROOT)/epoc32/release/armv5.phone3/urel/tc_variants.exe",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_mainTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_aTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_bTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/multiple_variants/traces/tc_cTraces.h",
        "$(EPOCROOT)/epoc32/ost_dictionaries/tc_variants_0x10000004_Dictionary.xml",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/tc_variants_0x10000004_TraceDefinitions.h"
    ]
    t.addbuildtargets(
        'smoke_suite/test_resources/tracecompiler/multiple_variants/group/bld.inf',
        [
            "tc_variants_/armv5.phone1/udeb/tc_main.o",
            "tc_variants_/armv5.phone1/udeb/tc_a.o",
            "tc_variants_/armv5.phone1/urel/tc_main.o",
            "tc_variants_/armv5.phone1/urel/tc_a.o",
            "tc_variants_/armv5.phone2/udeb/tc_main.o",
            "tc_variants_/armv5.phone2/udeb/tc_b.o",
            "tc_variants_/armv5.phone2/urel/tc_main.o",
            "tc_variants_/armv5.phone2/urel/tc_b.o",
            "tc_variants_/armv5.phone3/udeb/tc_main.o",
            "tc_variants_/armv5.phone3/udeb/tc_c.o",
            "tc_variants_/armv5.phone3/urel/tc_main.o",
            "tc_variants_/armv5.phone3/urel/tc_c.o",
            "tc_variants_/tracecompile_tc_variants_exe_10000004.done"
        ])
    t.run()

    # 102d and 102e is to test a very rare situation, where one mmpfile includes 3 children mmpfiles,
    # which are guarded by macros. They share some source file, and two share the same UID3.
    # When build them together, Raptor should be able to distinguish them and run trace compiler
    # on each of them.
    t = SmokeTest()
    t.id = "102d"
    t.name = "TC_mum_children_mmps_build"
    t.command = "sbs -b smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf" + \
      " -c armv5.tc_var1 -c armv5.tc_var2 -c armv5.tc_var3" + \
      " --configpath=test/smoke_suite/test_resources/tracecompiler/mum_children_mmps"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/udeb/child1.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/child1.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/child2.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/child2.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/child3.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/child3.exe",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child1_exe/child1Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child1_exe/commonTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/child2Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/commonTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/child3Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/commonTraces.h",
        "$(EPOCROOT)/epoc32/ost_dictionaries/child1_exe_0x11100001_Dictionary.xml",
        "$(EPOCROOT)/epoc32/ost_dictionaries/child2_exe_0x11100002_Dictionary.xml",
        "$(EPOCROOT)/epoc32/ost_dictionaries/child3_exe_0x11100002_Dictionary.xml",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child1_exe_0x11100001_TraceDefinitions.h",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child2_exe_0x11100002_TraceDefinitions.h",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child3_exe_0x11100002_TraceDefinitions.h"
    ]
    t.addbuildtargets(
        'smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf',
        [
            "child1_/armv5/udeb/child1.o", "child1_/armv5/udeb/common.o",
            "child1_/armv5/urel/child1.o", "child1_/armv5/urel/common.o",
            "child1_/tracecompile_child1_exe_11100001.done",
            "child2_/armv5/udeb/child2.o", "child2_/armv5/udeb/common.o",
            "child2_/armv5/urel/child2.o", "child2_/armv5/urel/common.o",
            "child2_/tracecompile_child2_exe_11100002.done",
            "child3_/armv5/udeb/child3.o", "child3_/armv5/udeb/common.o",
            "child3_/armv5/urel/child3.o", "child3_/armv5/urel/common.o",
            "child3_/tracecompile_child3_exe_11100002.done"
        ])
    t.warnings = 3
    t.run()

    # Clean mmp A then build mmp B and C. As common.cpp is shared by A B and C, commonTraces.h would be
    # cleaned when cleaning mmp A. But as B and C aren't cleaned, Raptor wouldn't run trace compiler on
    # B and C, thus commonTraces.h wouldn't be generated again, so be missing for mmp B and C.
    # The solution is to use new trace path "traces/traces_<TARGET>_<TARGETTYPE>" instead of "traces" so shared
    # source has different copy of trace headers for different projects.
    t = SmokeTest()
    t.id = "102e"
    t.name = "TC_mum_children_mmps_clean"
    t.command = "sbs -b smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf" + \
      " --configpath=test/smoke_suite/test_resources/tracecompiler/mum_children_mmps" + \
      " -c armv5.tc_var1 CLEAN && " + \
      "sbs -b smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf" + \
      " --configpath=test/smoke_suite/test_resources/tracecompiler/mum_children_mmps" + \
      " -c armv5.tc_var2 -c armv5.tc_var3"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/udeb/child2.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/child2.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/child3.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/child3.exe",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/child2Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child2_exe/commonTraces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/child3Traces.h",
        "$(SBS_HOME)/test/smoke_suite/test_resources/tracecompiler/mum_children_mmps/traces/child3_exe/commonTraces.h",
        "$(EPOCROOT)/epoc32/ost_dictionaries/child2_exe_0x11100002_Dictionary.xml",
        "$(EPOCROOT)/epoc32/ost_dictionaries/child3_exe_0x11100002_Dictionary.xml",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child2_exe_0x11100002_TraceDefinitions.h",
        "$(EPOCROOT)/epoc32/include/platform/symbiantraces/autogen/child3_exe_0x11100002_TraceDefinitions.h"
    ]
    t.addbuildtargets(
        'smoke_suite/test_resources/tracecompiler/mum_children_mmps/group/bld.inf',
        [
            "child2_/armv5/udeb/child2.o", "child2_/armv5/udeb/common.o",
            "child2_/armv5/urel/child2.o", "child2_/armv5/urel/common.o",
            "child2_/tracecompile_child2_exe_11100002.done",
            "child3_/armv5/udeb/child3.o", "child3_/armv5/udeb/common.o",
            "child3_/armv5/urel/child3.o", "child3_/armv5/urel/common.o",
            "child3_/tracecompile_child3_exe_11100002.done"
        ])
    t.warnings = 3
    t.run()

    t.id = "102"
    t.name = "tracecompiler_variants"
    t.print_result()

    return t
Exemplo n.º 10
0
def run():
	
	# This .inf file is created for clean_simple_export and
	# reallyclean_simple_export tests to use so that we can put the
	# username into the output filenames - which helps a lot when
	# several people run tests on the same computer (e.g. linux machines)
	bld_inf = open('smoke_suite/test_resources/simple_export/expbld.inf', 'w')
	user = os.environ['USER']
	bld_inf.write("""
	
PRJ_PLATFORMS
ARMV5 WINSCW

PRJ_MMPFILES
simple.mmp

PRJ_EXPORTS
#if !defined( WINSCW )
// Exports conditional on build configuration macros aren't actually supported,
// but we confirm that we preprocess in the context of an armv5 build when both
// winscw and armv5 configurations are (implicitly, as there's no "-c" argument)
// used.  This is in order to work around assumptions currently made in the
// source base.
simple_exp1.h exported_1.h
#endif
simple_exp2.h exported_2.h
simple_exp3.h exported_3.h
executable_file executable_file
"file with a space.doc" "exportedfilewithspacesremoved.doc"
"file with a space.doc" "exported file with a space.doc"

simple_exp1.h /tmp/{username}/  //
simple_exp2.h \\tmp\\{username}/  //
simple_exp3.h /tmp/{username}/simple_exp3.h 
simple_exp4.h //
read_only.h was_read_only.h //

// Extended format exports: support for filename wildcards and whole directory copying
:xexport xexport/dir1                                           xexport1
:xexport[invalid_arg=cobblers] xexport/dir1/dir2                +/xexport2
:xexport[recursive=true] xexport/dir1/dir2                      xexport3
:xexport[match="*1dir?.txt"] xexport/dir1/dir2                  +/xexport4
:xexport[match="*1dir?.txt" recursive=true] xexport/dir1/dir2   xexport5/subdir

""".format(username=user))
	bld_inf.close()
	
	exported_files = [
		"$(EPOCROOT)/epoc32/include/exported_1.h",
		"$(EPOCROOT)/epoc32/include/exported_2.h",
		"$(EPOCROOT)/epoc32/include/exported_3.h",
		"$(EPOCROOT)/epoc32/include/exportedfilewithspacesremoved.doc",
		"$(EPOCROOT)/epoc32/include/exported file with a space.doc",
		"/tmp/$(USER)/simple_exp1.h",
		"/tmp/$(USER)/simple_exp2.h",
		"/tmp/$(USER)/simple_exp3.h",
		"$(EPOCROOT)/epoc32/include/executable_file",
		"$(EPOCROOT)/epoc32/include/simple_exp4.h",
		"$(EPOCROOT)/epoc32/include/was_read_only.h",
		"$(EPOCROOT)/epoc32/include/xexport1/file1dir1.txt",
		"$(EPOCROOT)/epoc32/include/xexport1/file2dir1.txt",
		"$(EPOCROOT)/epoc32/xexport2/file1dir2.txt",
		"$(EPOCROOT)/epoc32/xexport2/file2dir2.txt",
		"$(EPOCROOT)/epoc32/include/xexport3/file1dir2.txt",
		"$(EPOCROOT)/epoc32/include/xexport3/file2dir2.txt",
		"$(EPOCROOT)/epoc32/include/xexport3/dir3/file1dir3.txt",
		"$(EPOCROOT)/epoc32/include/xexport3/dir3/file2dir3.txt",
		"$(EPOCROOT)/epoc32/xexport4/file1dir2.txt",
		"$(EPOCROOT)/epoc32/include/xexport5/subdir/file1dir2.txt",
		"$(EPOCROOT)/epoc32/include/xexport5/subdir/dir3/file1dir3.txt"
		]
	
	warning_match = ".*warning: Unrecognised ':xexport' argument 'invalid_arg=cobblers' ignored.*"

	t = AntiTargetSmokeTest()
	
	# Check basic export success
	t.name = "export_basic"
	t.command = "sbs -b smoke_suite/test_resources/simple_export/expbld.inf export"
	t.targets = exported_files
	t.antitargets = []
	t.mustmatch_singleline = [warning_match]
	t.warnings = 1
	t.run()
	
	# Confirm executable permissions are retained on Linux
	t.name = "export_executable_permissions"
	t.usebash = True
	t.command = "ls -l ${EPOCROOT}/epoc32/include/executable_file"
	t.mustmatch = [ "^.rwxrwxr.x[\.\+]? .*executable_file.*$" ]
	t.targets = [] # prevent auto clean-up up of target files from previous test
	t.antitargets = []
	t.mustmatch_singleline = []
	t.warnings = 0
	t.run("linux")

	# Check clean does not delete exports
	t.name = "export_clean"
	t.command = "sbs -b smoke_suite/test_resources/simple_export/expbld.inf clean"
	t.mustmatch = []
	t.targets = exported_files
	t.antitargets = []
	t.mustmatch_singleline = [warning_match]
	t.warnings = 1
	t.run()

	# Confirm reallyclean deletes all exports, including those that were read-only
	# as source (and so should now be removable at their destination)
	t.name = "export_reallyclean" 
	t.command = "sbs -b smoke_suite/test_resources/simple_export/expbld.inf reallyclean"
	t.targets = []
	t.antitargets = exported_files
	t.mustmatch_singleline = [warning_match]
	t.warnings = 1
	t.run()

	# Check --noexport suppresses exports
	t.name = "export_noexport" 
	t.command = "sbs -b smoke_suite/test_resources/simple_export/expbld.inf --noexport -n"
	t.targets = []
	t.antitargets = exported_files
	t.mustmatch_singleline = []
	t.warnings = 0
	t.run()
	
	# Clean all exports in a bld.inf with resources
	t.name = "component_with_resource_reallyclean" 
	t.command = "sbs -b smoke_suite/test_resources/resource/group/simple.inf reallyclean"
	t.targets = []
	t.antitargets = []
	t.mustmatch_singleline = []
	t.warnings = 0
	t.run()

	# Ensure that sbs EXPORT does not generate errors
	t.name = "export_generates_no_errors" 
	t.command = "sbs -b smoke_suite/test_resources/resource/group/simple.inf EXPORT"
	t.targets = [ "$(EPOCROOT)/epoc32/include/testresource_badef.rh",
				  "$(EPOCROOT)/epoc32/include/testresource.hrh"]
	t.antitargets = []
	t.errors = 0
	t.warnings = 0
	t.run()
	
	t.name = "export"
	t.print_result()
	return t
Exemplo n.º 11
0
def run():
    t = AntiTargetSmokeTest()
    t.description = """
		Tests the creation and content of .iby romfiles generated for the armv5.test
		configuration. Also tests for creation of relevant test batch files.
		"""
    t.usebash = True
    # Don't allow -m or -f to be appended
    t.logfileOption = lambda: ""
    t.makefileOption = lambda: ""

    # Check correct .iby and batch files are generated
    t.name = "romfile_general"
    t.command = "sbs -b $(EPOCROOT)/src/ongoing/group/romfile/other_name.inf " \
      + "-c armv5.test ROMFILE -m ${SBSMAKEFILE} -f ${SBSLOGFILE}"

    t.targets = [
        "$(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5test.iby",
        "$(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5testn.iby",
        "$(EPOCROOT)/epoc32/data/z/test/src_ongoing_romfile/armv5.auto.bat",
        "$(EPOCROOT)/epoc32/data/z/test/src_ongoing_romfile/armv5.manual.bat"
    ]
    t.warnings = 0 if t.onWindows else 2
    t.run()

    t.name = "romfile_content_exsymbian"
    t.command = "cat $(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5test.iby"
    t.mustmatch = [
        # The comment that is put at the start of the file.
        r".*// epoc32/rom/src/ongoing/group/romfile/armv5test\.iby\n.*",

        # The batch files that are added by the build system.
        r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.auto\.bat test/romfile\.auto\.bat\n.*",
        r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.manual\.bat test/romfile\.manual\.bat\n.*",

        # Some normal files.
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_rand\.exe\s+sys/bin/t_rand\.exe\n.*",
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_swapfsys\.exe\s+sys/bin/t_swapfsys\.exe\n.*",
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_localtime\.exe\s+sys/bin/t_localtime\.exe\n.*",

        # Some files where the MMP file has the PAGED or UNPAGED keywords.
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_pagestress\.exe\s+sys/bin/t_pagestress\.exe\n.*",
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_fsys\.exe\s+sys/bin/t_fsys\.exe\n.*",

        # Some files where the MMP file has the ROMTARGET or RAMTARGET keywords.
        r".*\ndata=/epoc32/release/##MAIN##/##BUILD##/t_prel\.dll\s+/sys/bin/t_prel\.dll attrib=r\n.*",
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+sys/bin/t_sysbin\.exe\n.*",
        r".*\ndata=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+/sys/bin/t_sysbin_ram\.exe attrib=r\n.*",
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+/sys/bin/t_sysbina\.exe\n.*",
        r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_sysbin\.exe\s+/system/programs/t_sysbinb\.exe\n.*",
    ]
    if t.onWindows:
        t.mustmatch.extend([
            # romstuff.mke additions - extension makefile added, so only apply on Windows
            r".*\ndata=..\\..\\f32test\\server\\t_file.cpp\s+Test\\T_file.cpp\n.*",
            r".*\ndata=..\\..\\f32test\\server\\t_findcaptestfile.txt\s+\\sys\\bin\\t_findcaptestfile.txt\n.*"
        ])
    t.mustnotmatch = [
        # Try to detect file paths that contain two or more slashes in a row,
        # without flagging C++ style comments.
        r"\w//+\w",

        # Confirm that no Nokia-format macros are present
        r"ABI_DIR",
        r"BUILD_DIR"
    ]
    t.targets = []
    t.warnings = 0
    t.run()

    t.name = "romfile_content_nokia"
    t.command = "cat $(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5testn.iby"
    t.mustmatch = [
        # The comment that is put at the start of the file.
        r".*// epoc32/rom/src/ongoing/group/romfile/armv5testn\.iby\n.*",

        # The batch files that are added by the build system.
        r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.auto\.bat test/romfile\.auto\.bat\n.*",
        r".*\ndata=/epoc32/data/z/test/src_ongoing_romfile/armv5\.manual\.bat test/romfile\.manual\.bat\n.*",

        # Some normal files.
        r".*\nfile=ABI_DIR/BUILD_DIR/t_rand\.exe\s+sys/bin/t_rand\.exe\n.*",
        r".*\nfile=ABI_DIR/BUILD_DIR/t_swapfsys\.exe\s+sys/bin/t_swapfsys\.exe\n.*",
        r".*\nfile=ABI_DIR/BUILD_DIR/t_localtime\.exe\s+sys/bin/t_localtime\.exe\n.*",

        # Some files where the MMP file has the PAGED or UNPAGED keywords.
        r".*\nfile=ABI_DIR/BUILD_DIR/t_pagestress\.exe\s+sys/bin/t_pagestress\.exe\n.*",
        r".*\nfile=ABI_DIR/BUILD_DIR/t_fsys\.exe\s+sys/bin/t_fsys\.exe\n.*",

        # Some files where the MMP file has the ROMTARGET or RAMTARGET keywords.
        r".*\ndata=ABI_DIR/BUILD_DIR/t_prel\.dll\s+/sys/bin/t_prel\.dll attrib=r\n.*",
        r".*\nfile=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+sys/bin/t_sysbin\.exe\n.*",
        r".*\ndata=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+/sys/bin/t_sysbin_ram\.exe attrib=r\n.*",
        r".*\nfile=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+/sys/bin/t_sysbina\.exe\n.*",
        r".*\nfile=ABI_DIR/BUILD_DIR/t_sysbin\.exe\s+/system/programs/t_sysbinb\.exe\n.*",

        # append_iby.flm additions from multiple START EXTENSION blocks
        r".*\ndata=../../f32test/server/t_file.cpp\s+Test/T_file.cpp\n.*",
        r".*\ndata=../../f32test/server/t_findcaptestfile.txt\s+/sys/bin/t_findcaptestfile.txt\n.*"
    ]
    t.mustnotmatch = [
        # Try to detect file paths that contain two or more slashes in a row,
        # without flagging C++ style comments.
        r"\w//+\w",

        # Confirm that no exSymbian-format macros are present
        r"##MAIN##",
        r"##BUILD##"
    ]
    t.targets = []
    t.warnings = 0
    t.run()

    t.name = "romfile_whatlog"
    t.command = "sbs -b $(EPOCROOT)/src/ongoing/group/romfile/other_name.inf " \
      + "-c armv5.test ROMFILE -f -"

    t.mustmatch = [
        # Check whatlog output includes batch files and .iby file
        r".*/epoc32/rom/src/ongoing/group/romfile/armv5test.iby</build>.*",
        r".*/epoc32/rom/src/ongoing/group/romfile/armv5testn.iby</build>.*",
        r".*/epoc32/data/z/test/src_ongoing_romfile/armv5.auto.bat</build>.*",
        r".*/epoc32/data/z/test/src_ongoing_romfile/armv5.manual.bat</build>.*"
    ]
    t.mustnotmatch = []
    t.warnings = 0 if t.onWindows else 2
    t.run()

    t.name = "romfile_mmp_include_twice_general"
    t.command = "sbs -b $(EPOCROOT)/src/e32test/group/bld.inf " \
            + "-b $(EPOCROOT)/src/falcon/test/bld.inf " \
      + "-c armv5.test ROMFILE -m ${SBSMAKEFILE} -f ${SBSLOGFILE} "

    t.targets = [
        "$(EPOCROOT)/epoc32/rom/src/e32test/group/armv5test.iby",
        "$(EPOCROOT)/epoc32/rom/src/e32test/group/armv5testn.iby"
    ]
    t.mustmatch = []
    t.warnings = 0
    t.run()

    t.name = "romfile_mmp_include_twice_content_exsymbian"
    t.command = "cat $(EPOCROOT)/epoc32/rom/src/e32test/group/armv5test.iby"
    t.targets = []
    t.mustmatch = [
        r".*\ndevice\[MAGIC\]=/epoc32/release/##KMAIN##/##BUILD##/d_nanowait\.ldd\s+sys/bin/d_nanowait\.ldd\n.*",
        r".*\ndevice\[MAGIC\]=/epoc32/release/##KMAIN##/##BUILD##/d_pagingexample_2_post.ldd\s+sys/bin/d_pagingexample_2_post.ldd\n.*",
    ]
    t.mustnotmatch = [
        # These two files are from two mmp files that included in both bld.inf
        # They shouldn't be in the ROM
        r".*/d_medch.ldd\s.*"
        r".*/d_dma.ldd\s.*"
    ]
    t.warnings = 0
    t.run()

    t.name = "romfile_mmp_include_twice_content_nokia"
    t.command = "cat $(EPOCROOT)/epoc32/rom/src/e32test/group/armv5testn.iby"
    t.targets = []
    t.mustmatch = [
        r".*\ndevice\[VARID\]=ABI_DIR/BUILD_DIR/d_nanowait\.ldd\s+sys/bin/d_nanowait\.ldd\n.*",
        r".*\ndevice\[VARID\]=ABI_DIR/BUILD_DIR/d_pagingexample_2_post.ldd\s+sys/bin/d_pagingexample_2_post.ldd\n.*",
    ]
    t.mustnotmatch = [
        # These two files are from two mmp files that included in both bld.inf
        # They shouldn't be in the ROM
        r".*/d_medch.ldd\s.*"
        r".*/d_dma.ldd\s.*"
    ]
    t.warnings = 0
    t.run()

    # Check armv5.auto.bat doesn't get generated with -p option
    t.name = "romfile_partial"
    t.command = "sbs -b $(EPOCROOT)/src/ongoing/group/romfile/other_name.inf " \
      + "-c armv5.test ROMFILE -p t_rcache.mmp"
    t.antitargets = [
        "$(EPOCROOT)/epoc32/data/z/test/src_ongoing_romfile/armv5.auto.bat"
    ]
    t.mustmatch = []
    t.mustnotmatch = []
    t.warnings = 0 if t.onWindows else 2
    t.run()

    t.name = "romfile"
    t.print_result()
    return t
Exemplo n.º 12
0
def run():
    t = AntiTargetSmokeTest()
    t.usebash = True

    genericTargets = [
        "$(EPOCROOT)/epoc32/release/armv5/udeb/dependency.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/dependency.exe.map",
        "$(EPOCROOT)/epoc32/release/armv5/urel/dependency.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/dependency.exe.map",
        "$(EPOCROOT)/epoc32/release/winscw/urel/dependency.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/dependency.exe.map",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/dependency.exe",
        "$(EPOCROOT)/epoc32/include/dependency.rsg",
        "$(EPOCROOT)/epoc32/data/z/resource/apps/dependency.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/dependency.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/dependency.rsc",
        "$(EPOCROOT)/epoc32/include/main.rsg",
        "$(EPOCROOT)/epoc32/data/z/resource/apps/main.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/main.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/main.rsc"
    ]
    windowsTargets = [
        "$(EPOCROOT)/epoc32/release/tools2/rel/dependency.exe",
        "$(EPOCROOT)/epoc32/tools/dependency.exe"
    ]
    linuxTargets = [
        "$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/rel/dependency",
        "$(EPOCROOT)/epoc32/tools/dependency"
    ]

    # Set general host platform specifics from first test run, but assume Windows initially
    hostPlatform = "windows"
    hostPlatformTargets = genericTargets + windowsTargets
    hostPlatformOffset = ""

    t.name = "baseline_build"
    t.description = "Build a component with source and resource files that are dependent on header files exported in the build"
    t.command = """
		cp smoke_suite/test_resources/dependencies/src/dependency1.cpp smoke_suite/test_resources/dependencies/dependency.cpp
		cp smoke_suite/test_resources/dependencies/src/dependency1.rss smoke_suite/test_resources/dependencies/dependency.rss
		sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
    t.mustnotmatch = ["<warning>Missing dependency detected: .*</warning>"]
    t.targets = hostPlatformTargets
    t.run(hostPlatform)
    if t.result == AntiTargetSmokeTest.SKIP:
        hostPlatform = "linux"
        hostPlatformTargets = genericTargets + linuxTargets
        hostPlatformOffset = "$(HOSTPLATFORM32_DIR)/"
        t.targets = hostPlatformTargets
        t.run(hostPlatform)

    # Ensure we don't clean up from the previous build in the following two tests
    t.targets = []

    # Core expected outcome for the following two tests
    t.mustmatch = [
        ".*recipe name='compile' target='.*dependency\.o'",
        ".*recipe name='win32compile2object' target='.*dependency\.o'",
        ".*recipe name='compile2object' target='.*dependency\.o'",
        ".*recipe name='resourcecompile' target='.*dependency\.rsc'"
    ]
    t.countmatch = [[".*recipe name='compile'", 2],
                    [".*recipe name='win32compile2object'", 2],
                    [".*recipe name='compile2object'", 1],
                    [".*recipe name='resourcecompile", 2]]

    t.name = "touched_header_dependencies"
    t.description = "Touch the exported header files and check that only the related source and resource files are re-built"
    t.command = """
		sleep 1
		touch $(EPOCROOT)/epoc32/include/dependency.h
		touch $(EPOCROOT)/epoc32/include/dependency.rh
		sbs -f- -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
    t.run()

    t.name = "redundant_header_dependencies"
    t.description = """
		Build the component again, but manipulate it so that (a) it no longer has a dependency on the exported header files and
		(b) the header files have been removed and (c) the header files are no longer exported.  Check that only the related source
		and resource files are re-built"""
    t.command = """
		cp smoke_suite/test_resources/dependencies/src/dependency2.cpp smoke_suite/test_resources/dependencies/dependency.cpp
		cp smoke_suite/test_resources/dependencies/src/dependency2.rss smoke_suite/test_resources/dependencies/dependency.rss
		rm -rf $(EPOCROOT)/epoc32/include/dependency.h
		rm -rf $(EPOCROOT)/epoc32/include/dependency.rh
		sbs -f- --noexport -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
    t.mustnotmatch = []
    # Note that the resource build does not exhibit a missing dependency as its dependency files are generated in a separate stage where
    # the target file isn't actually a target of that stage
    t.mustmatch.extend([
        "<warning>Missing dependency detected: .*/epoc32/include/dependency.h</warning>"
    ])
    t.warnings = 1
    t.run()

    t.name = "invalid_dependency_files"
    t.description = "Invalidate dependency files, then make sure we can clean and re-build successfully"
    buildLocation = "$(EPOCROOT)/epoc32/build/" + BldInfFile.outputPathFragment(
        'smoke_suite/test_resources/dependencies/bld.inf') + "/dependency_"
    # use one long bash command so that we can capture
    # the output in a way that isn't messed up with all the ordering confused.
    t.command = " echo \"making directory for logfile ${{SBSLOGFILE}}\" ; mkdir -p `dirname ${{SBSLOGFILE}} 2>/dev/null` ; {{ sleep 1 ; set -x ; \
touch smoke_suite/test_resources/dependencies/dependency.cpp; \
echo INVALIDATE_ARMV5_DEPENDENCY_FILE >> {0}/armv5/urel/dependency.o.d ; \
echo INVALIDATE_WINSCW_DEPENDENCY_FILE >> {0}/winscw/urel/dependency.o.d ;\
echo INVALIDATE_TOOLS2_DEPENDENCY_FILE >> {0}/dependency_exe/tools2/rel/{1}/dependency.o.d ;\
echo INVALIDATE_RESOURCE_DEPENDENCY_FILE >> {0}/dependency__resource_apps.rsc.d ;\
sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel ;\
sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel clean ;\
sbs -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel ; }} > ${{SBSLOGFILE}} 2>&1; grep 'missing separator' ${{SBSLOGFILE}} ".format(
        buildLocation, hostPlatformOffset)
    # We expect an error from the first build due to the deliberate dependency file corruption
    t.mustmatch = [".*dependency.o.d:[0-9]+: \*\*\* missing separator"]
    t.countmatch = []
    t.warnings = 0
    t.errors = 0
    t.targets = hostPlatformTargets
    t.run(hostPlatform)

    t.name = "no_depend_include"
    t.description = "Invalidate dependency files in order to confirm they aren't processed when --no-depend-include is used"
    buildLocation = "$(EPOCROOT)/epoc32/build/" + BldInfFile.outputPathFragment(
        'smoke_suite/test_resources/dependencies/bld.inf') + "/dependency_"
    t.command = """
		sleep 1
		touch smoke_suite/test_resources/dependencies/dependency.cpp
		echo INVALIDATE_ARMV5_DEPENDENCY_FILE >> """ + buildLocation + """/armv5/urel/dependency.o.d
		echo INVALIDATE_WINSCW_DEPENDENCY_FILE >> """ + buildLocation + """/winscw/urel/dependency.o.d
		echo INVALIDATE_TOOLS2_DEPENDENCY_FILE >> """ + buildLocation + """/dependency_exe/tools2/rel/""" + hostPlatformOffset + """dependency.o.d
		sbs --no-depend-include -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
    t.mustmatch = []
    t.errors = 0
    t.targets = hostPlatformTargets
    t.run(hostPlatform)

    t.name = "no_depend_generate"
    t.description = "Invalidate and remove dependency files in order to confirm they are neither included nor re-generated when --no-depend-generate is used"
    buildLocation = "$(EPOCROOT)/epoc32/build/" + BldInfFile.outputPathFragment(
        'smoke_suite/test_resources/dependencies/bld.inf') + "/dependency_"
    t.command = """
		sleep 1
		touch smoke_suite/test_resources/dependencies/dependency.cpp
		touch smoke_suite/test_resources/dependencies/main.cpp
		echo INVALIDATE_ARMV5_DEPENDENCY_FILE >> """ + buildLocation + """/armv5/urel/dependency.o.d
		echo INVALIDATE_WINSCW_DEPENDENCY_FILE >> """ + buildLocation + """/winscw/urel/dependency.o.d
		echo INVALIDATE_TOOLS2_DEPENDENCY_FILE >> """ + buildLocation + """/dependency_exe/tools2/rel/""" + hostPlatformOffset + """dependency.o.d
		sbs --no-depend-generate -b smoke_suite/test_resources/dependencies/bld.inf -c default -c tools2_rel"""
    t.antitargets = [
        buildLocation + "/armv5/urel/main.o.d",
        buildLocation + "/armv5/udeb/main.o.d",
        buildLocation + "/winscw/urel/main.o.d",
        buildLocation + "/winscw/udeb/main.o.d", buildLocation +
        "/dependency_exe/tools2/rel/" + hostPlatformOffset + "main.o.d"
    ]
    t.targets = hostPlatformTargets
    t.run(hostPlatform)

    # clean-up
    os.remove("smoke_suite/test_resources/dependencies/dependency.cpp")
    os.remove("smoke_suite/test_resources/dependencies/dependency.rss")

    t.name = "dependencies"
    t.print_result()
    return t