Пример #1
0
def run():
	t = SmokeTest()
	t.usebash = True

	t.name = "var_test"
	t.command = "sbs -b smoke_suite/test_resources/variable_test/bld.inf -c armv7 -f ${SBSLOGFILE} -m ${SBSMAKEFILE} && cat ${SBSLOGFILE}"
	t.targets = []
	t.mustmatch = ["<debug>SBS=.*/bin/sbs\.bat</debug>"]
	t.run("windows")

	t.mustmatch = ["<debug>SBS=.*/bin/sbs</debug>"]
	t.run("linux")
	
	return t
Пример #2
0
def run():
    t = SmokeTest()
    t.usebash = True

    t.name = "var_test"
    t.command = "sbs -b smoke_suite/test_resources/variable_test/bld.inf -c armv7 -f ${SBSLOGFILE} -m ${SBSMAKEFILE} && cat ${SBSLOGFILE}"
    t.targets = []
    t.mustmatch = ["<debug>SBS=.*/bin/sbs\.bat</debug>"]
    t.run("windows")

    t.mustmatch = ["<debug>SBS=.*/bin/sbs</debug>"]
    t.run("linux")

    return t
Пример #3
0
def run():
	t = SmokeTest()
	
	t.id = "71a"
	t.name = "implib_implicit_def"
	t.command = "sbs -b smoke_suite/test_resources/simple_implib/nodef/group/bld.inf" \
			+ " -p implib_implicit_def.mmp"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/lib/implib_implicit_def.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/implib_implicit_def{000a0000}.dso",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/implib_implicit_def.lib"
		]
	t.run()

	t.id = "71b"
	t.name = "implib_no_def"
	t.command = "sbs -b smoke_suite/test_resources/simple_implib/nodef/group/bld.inf" \
			+ " -p implib_no_def.mmp"
	t.targets = []
	t.mustmatch = [
		"No DEF File for IMPLIB target type in"	
		]
	t.errors = 2 # 1 for winscw and 1 for armv5
	t.returncode = 1
	t.run()

	t.id = "71"
	t.name = "implib_nodef"
	t.print_result()

	return t
Пример #4
0
def run():
	t = SmokeTest()
	t.id = "0096"
	t.name = "kdll_armv5"
	t.usebash = 1

	t.command = "sbs -b smoke_suite/test_resources/simple_kdll/bld.inf -c armv5_urel -f-"

	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_kdll.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_kdll.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_kdll.dll.sym"
		]

	t.mustmatch = [
		r".*\bksrt\d_\d\.lib\b.*",
		r".*\bekll\.lib\b.*"
		]

	t.mustnotmatch = [
		r".*usrt.*",
		r".*scppnwdl.*"
		]

	t.run()
	return t
Пример #5
0
def run():

    t = SmokeTest()

    # Should have returncode of 1 and output 1 error, but not cause a traceback
    t.returncode = 1
    t.errors = 1
    t.mustmatch = [
        "sbs: error: Non-ASCII character in argument or command file"
    ]

    result = SmokeTest.PASS

    t.name = "non_ascii_argument"

    t.usebash = True
    # The dash in "-c" is an en dash, not a normal ASCII dash.
    t.command = r'set -x;sbs -b smoke_suite/test_resources/simple_dll/bld.inf `echo -e "\x96"`c armv5'

    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.name = "non_ascii_commandfile"

    t.command = "sbs --command=smoke_suite/test_resources/non_ascii/cmd.txt"

    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.name = "non_ascii"
    t.result = result
    t.print_result()
    return t
Пример #6
0
def run():
	t = SmokeTest()
	t.id = "33"
	t.name = "exe_winscw"
	t.usebash = True
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c winscw -m ${SBSMAKEFILE} -f ${SBSLOGFILE}; grep -E \"mwldsym2\" ${SBSLOGFILE}"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/winscw/udeb/test.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test.exe.map"
		]
	t.addbuildtargets('smoke_suite/test_resources/simple/bld.inf', [
		"test_/winscw/udeb/test.o",
		"test_/winscw/udeb/test_.o",
		"test_/winscw/udeb/test_UID_.o",
		"test_/winscw/udeb/test.UID.CPP",
		"test_/winscw/urel/test.o",
		"test_/winscw/urel/test_.o",
		"test_/winscw/urel/test_UID_.o",
		"test_/winscw/urel/test.UID.CPP"
	])
	# Check that the default operator new library is used
	t.mustmatch = [
		'.*mwldsym2.*scppnwdl.lib.*test.exe.*'
		]
	t.run()
	return t
Пример #7
0
def run():
	t = SmokeTest()
	t.id = "2"
	t.name = "exe_armv5_filtered"
	t.description = "Run exe_armv5 with a customised filter. Will create then" \
			+ " remove filter file"
	t.usebash = True
	t.command = "cp -f smoke_suite/test_resources/filter_test/testfilter.py ../raptor/plugins/testfilter.py " \
				"&& chmod 600 ../raptor/plugins/testfilter.py " \
				"&& sbs -b smoke_suite/test_resources/simple/bld.inf -c armv5 --filters=TestFilter " \
				"&& rm -f ../raptor/plugins/testfilter.py*"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe.map"
		]
	t.addbuildtargets('smoke_suite/test_resources/simple/bld.inf', [
		"test_/armv5/udeb/test.o",
		"test_/armv5/urel/test.o"
	])
	t.mustmatch = [
		".*Test Passed!.*"
		]
	t.run()
	return t
Пример #8
0
def run():
	t = SmokeTest()
	t.id = "2"
	t.name = "exe_armv5_filtered"
	t.description = "Run exe_armv5 with a customised filter. Will create then" \
			+ " remove filter file"
	t.usebash = True
	t.command = "cp -f smoke_suite/test_resources/filter_test/testfilter.py ../python/plugins/testfilter.py " \
				"&& chmod 600 ../python/plugins/testfilter.py " \
				"&& sbs -b smoke_suite/test_resources/simple/bld.inf -c armv5 --filters=TestFilter " \
				"&& rm -f ../python/plugins/testfilter.py*"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe.map"
		]
	t.addbuildtargets('smoke_suite/test_resources/simple/bld.inf', [
		"test_/armv5/udeb/test.o",
		"test_/armv5/urel/test.o"
	])
	t.mustmatch = [
		".*Test Passed!.*"
		]
	t.run()
	return t
Пример #9
0
def run():
	t = SmokeTest()
	t.usebash = True
	
	t.description = "Test that a timing log is created and contains total parse and build durations"

	t.id = "0103b"
	t.name = "timing_on"
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf" + \
			" --filters=FilterLogfile,FilterTiming -f ${SBSLOGFILE} && " + \
			"grep progress:duration ${SBSLOGFILE}.timings"
	t.mustmatch = [
			"^<progress:duration object_type='layer' task='parse' key='.*' duration='\d+.\d+' />$",
			"^<progress:duration object_type='layer' task='build' key='.*' duration='\d+.\d+' />$",
			"^<progress:duration object_type='all' task='all' key='all' duration='\d+.\d+' />$"
			]
	t.mustnotmatch = []
	t.run()


	t.id = "103"
	t.name = "timing"
	t.print_result()
	
	return t
Пример #10
0
def run():

	t = SmokeTest()

	# Should have returncode of 1 and output 1 error, but not cause a traceback
	t.returncode = 1
	t.errors = 1
	t.mustmatch = ["sbs: error: Non-ASCII character in argument or command file"]

	result = SmokeTest.PASS

	t.name = "non_ascii_argument"

	t.usebash = True
	# The dash in "-c" is an en dash, not a normal ASCII dash.
	t.command = r'set -x;sbs -b smoke_suite/test_resources/simple_dll/bld.inf `echo -e "\x96"`c armv5'

	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL

	t.name = "non_ascii_commandfile"

	t.command = "sbs --command=smoke_suite/test_resources/non_ascii/cmd.txt"

	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL

	t.name = "non_ascii"
	t.result = result
	t.print_result()
	return t
Пример #11
0
def run():
    t = SmokeTest()
    t.name = "make_engine_filenames"
    t.description = "Can we pass the makefilename and stage name to emake options like --annofile etc?"

    t.mustmatch = [
        ".*Executing.*emake.*historyfile=.*default\.history.*",
        ".*Executing.*emake.*annofile=.*\.default\.anno.*"
    ]

    t.mustnotmatch = [
        ".*Executing.*emake.*historyfile=.*#STAGE#\.history.*",
        ".*Executing.*emake.*annofile=#MAKEFILE#\.anno.*"
    ]

    t.usebash = True
    t.errors = 1
    t.returncode = 1
    base_command = "sbs generate -b smoke_suite/test_resources/simple/bld.inf -f-"

    t.command = base_command + " -e emake --mo=--emake-annofile=#MAKEFILE#.anno --mo=--emake-historyfile=$(EPOCROOT)/epoc32/build/#STAGE#.history -k NOTARGET"
    t.run()

    t.print_result()
    return t
Пример #12
0
def run():
	t = SmokeTest()
	t.usebash = True

	if "SBS_ELF2E32" in os.environ:
		elf2e32 = os.environ["SBS_ELF2E32"]
	elif sys.platform.startswith("win"):
		elf2e32 = "$(EPOCROOT)/epoc32/tools/elf2e32.exe"
	else:
		elf2e32 = "$(EPOCROOT)/epoc32/tools/elf2e32"

	description = """This test attempts to check that an exe gets the capabilities that we requested.  It's ARM specific since it uses elf2e32. Tries to demonstrate capabilties being turned off then on in the mmp."""
	command = "sbs -b smoke_suite/test_resources/simple/capability.inf -c %s -m ${SBSMAKEFILE} -f ${SBSLOGFILE} && " + \
			  elf2e32 + " --dump=s  --e32input=$(EPOCROOT)/epoc32/release/armv5/urel/test_capability.exe"
	targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_capability.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_capability.exe.map"
		]	
	buildtargets = [
		]
	mustmatch = [
		"\s*Secure ID: 10003a5c$",
		"\s*Vendor ID: 00000000$",
		"\s*Capabilities: 00000000 000fffbf$",
		"\s*CommDD$",
		"\s*PowerMgmt$",
		"\s*MultimediaDD$",
		"\s*ReadDeviceData$",
		"\s*WriteDeviceData$",
		"\s*TrustedUI$",
		"\s*DiskAdmin$",
		"\s*NetworkControl$",
		"\s*AllFiles$",
		"\s*SwEvent$",
		"\s*NetworkServices$",
		"\s*LocalServices$",
		"\s*ReadUserData$",
		"\s*WriteUserData$",
		"\s*Location$",
		"\s*SurroundingsDD$",
		"\s*UserEnvironment$",
		"\s*TCB$"
	]
	mustnotmatch = [
		"DRM"
	]
	warnings = 0
	
	t.id = "0107"
	t.name = "capability_arm"
	t.description = description
	t.command = command % "arm.v5.urel.gcce4_4_1"
	t.targets = targets
	t.mustmatch = mustmatch
	t.mustnotmatch = mustnotmatch
	t.warnings = warnings
	t.run()
	return t
Пример #13
0
def run():
    t = SmokeTest()
    t.description = "Set of tests for commandline option validation e.g. checking that the specified make engine exists"

    t.usebash = True
    t.errors = 1
    t.returncode = 1
    t.exceptions = 0
    base_command = "sbs -b smoke_suite/test_resources/simple/bld.inf -f ${SBSLOGFILE} -m ${SBSMAKEFILE}"

    t.id = "42562a"
    t.name = "validate_makeengine_nonexist"
    t.command = base_command + " -e amakeenginethatdoesnotexist"
    t.mustmatch = [
        "Unable to use make engine: 'amakeenginethatdoesnotexist' does not appear to be a make engine - no settings found for it"
    ]

    t.run()

    t.id = "43562b"
    t.mustmatch = [
        "Unable to use make engine: 'arm' is not a build engine \(it's a variant but it does not extend 'make_engine'"
    ]
    t.name = "validate_makeengine_is_a_non_makengine_variant"
    t.command = base_command + " -e arm"
    t.run()

    # aliases can be of the form name='blah' meaning='x.y.z'  i.e. where the alias is for a sequence of variants
    # this tests that we detect that at least one of these variants has make_engine as a parent
    # it is possible for one of them not to and we mustn't bomb-out just because of that
    t.id = "43562c"
    t.mustmatch = []
    t.name = "validate_real_dfs_modded_makeengine_alias"
    t.command = "export HOME=$SBS_HOME/test/custom_options/dfsconfig;  " + base_command + " -e dfstestmake -c arm.v5.urel.gcce4_4_1"
    t.errors = 0
    t.warnings = 0
    t.returncode = 0
    t.run()

    t.id = "43562"
    t.name = "input_validation"
    t.print_result()
    return t
Пример #14
0
def run():
	t = SmokeTest()
	t.description = "Set of tests for commandline option validation e.g. checking that the specified make engine exists"
	
	
	t.usebash = True
	t.errors = 1
	t.returncode = 1
	t.exceptions = 0
	base_command = "sbs -b smoke_suite/test_resources/simple/bld.inf -f ${SBSLOGFILE} -m ${SBSMAKEFILE}"
	
	t.id = "42562a"
	t.name = "validate_makeengine_nonexist"
	t.command = base_command + " -e amakeenginethatdoesnotexist"
	t.mustmatch = ["Unable to use make engine: 'amakeenginethatdoesnotexist' does not appear to be a make engine - no settings found for it"]

	t.run()

	t.id = "43562b"
	t.mustmatch = ["Unable to use make engine: 'arm' is not a build engine \(it's a variant but it does not extend 'make_engine'"]
	t.name = "validate_makeengine_is_a_non_makengine_variant"
	t.command = base_command + " -e arm"
	t.run()

	# aliases can be of the form name='blah' meaning='x.y.z'  i.e. where the alias is for a sequence of variants
	# this tests that we detect that at least one of these variants has make_engine as a parent
	# it is possible for one of them not to and we mustn't bomb-out just because of that
	t.id = "43562c"
	t.mustmatch = []
	t.name = "validate_real_dfs_modded_makeengine_alias"
	t.command = "export HOME=$SBS_HOME/test/custom_options/dfsconfig;  " + base_command + " -e dfstestmake -c arm.v5.urel.gcce4_4_1"
	t.errors = 0
	t.warnings = 0
	t.returncode = 0
	t.run()
	
	t.id = "43562"
	t.name = "input_validation"
	t.print_result()
	return t
Пример #15
0
def run():
	t = SmokeTest()
	t.description = "tests that previous crash conditions now generate tidy errors."
	
	# no crash when there are bld.inf lines starting with a slash	
	t.id = "45a"
	t.name = "raptor_crash"
	t.command = "sbs -b smoke_suite/test_resources/simple_crash/bld.inf"
	t.errors = 2
	t.returncode = 1
	t.run()
	
	# should get an error code when running inside cmd
	t.id = "45b"
	t.name = "error_cmd"
	t.usebash = True
	t.command = "cmd /c sbs -s no_such_thing"
	t.mustmatch = ["System Definition file no_such_thing does not exist"]
	t.errors = 1
	t.returncode = 1
	t.run("windows")
	
	# should get an error code when running in bash
	t.id = "45c"
	t.name = "error_bash"
	t.usebash = True
	t.command = "sbs -s no_such_thing"
	t.mustmatch = ["System Definition file no_such_thing does not exist"]
	t.errors = 1
	t.returncode = 1
	t.run()
	
	# print the over all result
	t.id = "45"
	t.name = "raptor_crash"
	t.print_result()
	return t
Пример #16
0
def run():
    t = SmokeTest()
    t.description = "tests that previous crash conditions now generate tidy errors."

    # no crash when there are bld.inf lines starting with a slash
    t.id = "45a"
    t.name = "raptor_crash"
    t.command = "sbs -b smoke_suite/test_resources/simple_crash/bld.inf"
    t.errors = 2
    t.returncode = 1
    t.run()

    # should get an error code when running inside cmd
    t.id = "45b"
    t.name = "error_cmd"
    t.usebash = True
    t.command = "cmd /c sbs -s no_such_thing"
    t.mustmatch = ["System Definition file no_such_thing does not exist"]
    t.errors = 1
    t.returncode = 1
    t.run("windows")

    # should get an error code when running in bash
    t.id = "45c"
    t.name = "error_bash"
    t.usebash = True
    t.command = "sbs -s no_such_thing"
    t.mustmatch = ["System Definition file no_such_thing does not exist"]
    t.errors = 1
    t.returncode = 1
    t.run()

    # print the over all result
    t.id = "45"
    t.name = "raptor_crash"
    t.print_result()
    return t
def run():
	t = SmokeTest()
	t.id = "90"
	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 default UID2 settings for PLUGIN3 TARGETTYPEs and default resource generation locations
		for both PLUGIN and PLUGIN3."""
	t.usebash = True
	
	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"		
		]
	
	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
Пример #18
0
def run():
	t = SmokeTest()
	t.name = "cli_makevar_overide"
	t.id = "0117"
	t.description = "Attempt to override a makefile var at the command line."
	t.usebash = True
	
	t.command = "sbs -b smoke_suite/test_resources/basics/helloworld/Bld.inf REALLYCLEAN -m ${SBSMAKEFILE} -f ${SBSLOGFILE} HOSTPLATFORM_DIR=unlikelydir"  
	
	t.mustmatch = ["sbs: warning: CLEAN, CLEANEXPORT and a REALLYCLEAN should not be combined with other targets as the result is unpredictable"]
	
	t.warnings = 1
	t.run()
	
	return t
	
Пример #19
0
def run():
	t = SmokeTest()
	t.usebash = True
	result = SmokeTest.PASS

	description = """This test covers parallel parsing."""
	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 "

	mmpcount = 10 # how many mmps in this parallel parsing test

	
	target_templ = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe.sym"
	]

	targets = []

	# Build up target list for 10 similar executables
	for num in range(1,mmpcount):
		for atarget in target_templ:
			targets.append(atarget.replace('pp#','pp'+ str(num)))

	mustmatch = [
		".*<recipe .*name='makefile_generation.*",
	]
	mustnotmatch = [
		".*<recipe .*name='makefile_generation_export.*",
		".*<error[^><]*>.*"
	]

	warnings = 0
		
	t.id = "104"
	t.name = "parallel_parsing"
	t.description = description
	t.command = command 
	t.targets = targets
	t.mustmatch = mustmatch
	t.mustnotmatch = mustnotmatch
	t.warnings = warnings
	t.run()
	return t
Пример #20
0
def run():
    t = SmokeTest()
    t.name = "cli_makevar_overide"
    t.id = "0117"
    t.description = "Attempt to override a makefile var at the command line."
    t.usebash = True

    t.command = "sbs -b smoke_suite/test_resources/basics/helloworld/Bld.inf REALLYCLEAN -m ${SBSMAKEFILE} -f ${SBSLOGFILE} HOSTPLATFORM_DIR=unlikelydir"

    t.mustmatch = [
        "sbs: warning: CLEAN, CLEANEXPORT and a REALLYCLEAN should not be combined with other targets as the result is unpredictable"
    ]

    t.warnings = 1
    t.run()

    return t
Пример #21
0
def run():
    t = SmokeTest()
    t.name = "bad_config"

    t.description = """Checks that if you give an incomplete (unbuildable) configuration that raptor complains nicely without a traceback."""

    t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c arm.v5.rvct4_0 -c arm.v5.rvct2_2"  # missing "urel" or "udeb"
    t.targets = []
    t.mustmatch = [
        "sbs: error: arm.v5.rvct2_2 is a bad configuration: Unset variable '.*' used in spec 'none' with config 'none'",
        "sbs: error: arm.v5.rvct4_0 is a bad configuration: Unset variable '.*' used in spec 'none' with config 'none'",
        "sbs: error: Build stopped because the following requested configurations are incomplete or invalid: arm.v5.rvct2_2, arm.v5.rvct4_0"
    ]
    t.mustnotmatch = [".*Traceback.*", ".*UninitialisedVariableException.*"]
    t.errors = 3
    t.returncode = 1

    t.run()
    return t
Пример #22
0
def run():
    t = SmokeTest()
    t.id = "8"
    t.name = "bitmap"
    t.description = "This step is for testing BITMAP keyword and MIFCONV support for s60"
    t.usebash = True
    t.command = "sbs -b smoke_suite/test_resources/bitmap/bld.inf BITMAP && grep -ir 'MIFCONV_TEST:=1' $(EPOCROOT)/epoc32/build"
    t.targets = [
        "$(EPOCROOT)/epoc32/include/testbitmap.mbg",
        "$(EPOCROOT)/epoc32/data/z/resource/apps/testbitmap.mBm",
        "$(EPOCROOT)/epoc32/tools/makefile_templates/test/mifconv.xml",
        "$(EPOCROOT)/epoc32/tools/makefile_templates/test/mifconv.flm"
    ]
    t.addbuildtargets('smoke_suite/test_resources/bitmap/bld.inf',
                      ["testbitmap_dll/testbitmap.mBm_bmconvcommands"])
    t.mustmatch = [".*Makefile.*(_all)?.bitmap:MIFCONV_TEST:=1.*"]
    t.mustnotmatch = [".*Makefile.*(_all)?.default:MIFCONV_TEST.*"]
    t.run()
    return t
Пример #23
0
def run():
	t = SmokeTest()
	
	t.name = "exported_flm_extension"
	t.command = "sbs -b smoke_suite/test_resources/simple_extension/flm_bld.inf -c armv5"
	t.targets = [
		"$(EPOCROOT)/epoc32/build/flm_test_1_2",
		"$(EPOCROOT)/epoc32/tools/makefile_templates/tools/flm_export.xml",
		"$(EPOCROOT)/epoc32/tools/makefile_templates/tools/flm_export.flm"
		]
	t.run()
	
	t.name = "per_component_flm"
	t.usebash = True
	t.command = "sbs --configpath=test/smoke_suite/test_resources/docs" + \
	            " -b smoke_suite/test_resources/simple_dll/bld.inf" + \
	            " -b smoke_suite/test_resources/simple_lib/bld.inf" + \
	            " -b smoke_suite/test_resources/tools2/bld.inf" + \
	            " -c armv5.documentation -c tools2.documentation -f-"
	t.targets = [         
		"$(EPOCROOT)/epoc32/docs/simple_dll.txt",
		"$(EPOCROOT)/epoc32/docs/CreateStaticDLL.mmp",

		"$(EPOCROOT)/epoc32/docs/simple_lib.txt",
		"$(EPOCROOT)/epoc32/docs/simple.mmp",

		"$(EPOCROOT)/epoc32/docs/tools2.txt",
		"$(EPOCROOT)/epoc32/docs/tool_exe.mmp",
		"$(EPOCROOT)/epoc32/docs/tool_lib1.mmp",
		"$(EPOCROOT)/epoc32/docs/tool_lib2.mmp"
		]
	t.mustmatch = [
		"simple_dll.txt uses " + ReplaceEnvs(t.targets[1]),
		"simple_lib.txt uses " + ReplaceEnvs(t.targets[3]),
		"tools2.txt uses " + ReplaceEnvs(t.targets[5]) + " " + \
		                     ReplaceEnvs(t.targets[6]) + " " + \
		                     ReplaceEnvs(t.targets[7])
		]
	t.run()
		
	t.name = "flm_extension"
	t.print_result()
	return t
Пример #24
0
def run():
	t = SmokeTest()
	t.id = "85a"
	t.name = "commandline_nodefaults"
	t.description = """Test that raptor complains if you run it without specifying any components and there is no default bld.inf or system definition in the current directory."""
	t.usebash = True
			
	t.command = """
		TMPDIR="build/commandline_testdefaults";
		cd $(EPOCROOT)/epoc32 && rm -rf "$TMPDIR" 2>/dev/null; mkdir -p "$TMPDIR" && cd "$TMPDIR" &&
		sbs ${SBSLOGFILE} -n ; rm -rf "$TMPDIR"
	""" 
		
	t.mustmatch = [".*warning: No default bld.inf or system definition.*found.* "]
	t.warnings = 1
	t.run()

	t.id = "0085"
	t.name = "commandline"
	return t
Пример #25
0
def run():
    t = SmokeTest()
    t.id = "0096"
    t.name = "kdll_armv5"
    t.usebash = 1

    t.command = "sbs -b smoke_suite/test_resources/simple_kdll/bld.inf -c armv5_urel -f-"

    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/urel/test_kdll.dll",
        "$(EPOCROOT)/epoc32/release/armv5/urel/test_kdll.dll.map",
        "$(EPOCROOT)/epoc32/release/armv5/urel/test_kdll.dll.sym"
    ]

    t.mustmatch = [r".*\bksrt\d_\d\.lib\b.*", r".*\bekll\.lib\b.*"]

    t.mustnotmatch = [r".*usrt.*", r".*scppnwdl.*"]

    t.run()
    return t
Пример #26
0
def run():
	t = SmokeTest()
	t.description = "This testcase tests specific cases of using APPLY"
	t.usebash = True

	# Introduce LINKER_OPTIONS for tools2 linker
	t.id = "0108"
	t.name = "apply_usecases"
	t.command = "sbs -b smoke_suite/test_resources/apply_usecases/linker_options/bld.inf -c tools2 -f -"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/tools2/rel/test_apply_linkeroptions.exe"
		]
	t.addbuildtargets("smoke_suite/test_resources/apply_usecases/linker_options/bld.inf", [
		"test_apply_linkeroptions_/test_apply_linkeroptions_exe/tools2/deb/test_apply_linkeroptions.o",
		"test_apply_linkeroptions_/test_apply_linkeroptions_exe/tools2/rel/test_apply_linkeroptions.o"
	])
	t.mustmatch = ["-lwsock32"]
	t.run("windows")

	return t
Пример #27
0
def run():
    t = SmokeTest()

    t.name = "exported_flm_extension"
    t.command = "sbs -b smoke_suite/test_resources/simple_extension/flm_bld.inf -c armv5"
    t.targets = [
        "$(EPOCROOT)/epoc32/build/flm_test_1_2",
        "$(EPOCROOT)/epoc32/tools/makefile_templates/tools/flm_export.xml",
        "$(EPOCROOT)/epoc32/tools/makefile_templates/tools/flm_export.flm"
    ]
    t.run()

    t.name = "per_component_flm"
    t.usebash = True
    t.command = "sbs --configpath=test/smoke_suite/test_resources/docs" + \
                " -b smoke_suite/test_resources/simple_dll/bld.inf" + \
                " -b smoke_suite/test_resources/simple_lib/bld.inf" + \
                " -b smoke_suite/test_resources/tools2/bld.inf" + \
                " -c armv5.documentation -c tools2.documentation -f-"
    t.targets = [
        "$(EPOCROOT)/epoc32/docs/simple_dll.txt",
        "$(EPOCROOT)/epoc32/docs/CreateStaticDLL.mmp",
        "$(EPOCROOT)/epoc32/docs/simple_lib.txt",
        "$(EPOCROOT)/epoc32/docs/simple.mmp",
        "$(EPOCROOT)/epoc32/docs/tools2.txt",
        "$(EPOCROOT)/epoc32/docs/tool_exe.mmp",
        "$(EPOCROOT)/epoc32/docs/tool_lib1.mmp",
        "$(EPOCROOT)/epoc32/docs/tool_lib2.mmp"
    ]
    t.mustmatch = [
     "simple_dll.txt uses " + ReplaceEnvs(t.targets[1]),
     "simple_lib.txt uses " + ReplaceEnvs(t.targets[3]),
     "tools2.txt uses " + ReplaceEnvs(t.targets[5]) + " " + \
                          ReplaceEnvs(t.targets[6]) + " " + \
                          ReplaceEnvs(t.targets[7])
     ]
    t.run()

    t.name = "flm_extension"
    t.print_result()
    return t
Пример #28
0
def run():
    t = SmokeTest()
    t.description = "This testcase tests specific cases of using APPLY"
    t.usebash = True

    # Introduce LINKER_OPTIONS for tools2 linker
    t.id = "0108"
    t.name = "apply_usecases"
    t.command = "sbs -b smoke_suite/test_resources/apply_usecases/linker_options/bld.inf -c tools2 -f -"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/tools2/rel/test_apply_linkeroptions.exe"
    ]
    t.addbuildtargets(
        "smoke_suite/test_resources/apply_usecases/linker_options/bld.inf", [
            "test_apply_linkeroptions_/test_apply_linkeroptions_exe/tools2/deb/test_apply_linkeroptions.o",
            "test_apply_linkeroptions_/test_apply_linkeroptions_exe/tools2/rel/test_apply_linkeroptions.o"
        ])
    t.mustmatch = ["-lwsock32"]
    t.run("windows")

    return t
Пример #29
0
def run():
	t = SmokeTest()
	t.id = "29"
	t.name = "armv7_testcode"
	t.command = "sbs -b smoke_suite/test_resources/simple_test/bld.inf -c " + \
			"armv7.test -f - "
	
	# Don't allow -f to be appended
	t.logfileOption = lambda :""
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv7/urel/simple_test_auto.exe",
		"$(EPOCROOT)/epoc32/release/armv7/urel/simple_test_manual.exe",
		"$(EPOCROOT)/epoc32/release/armv7/udeb/simple_test_auto.exe",
		"$(EPOCROOT)/epoc32/release/armv7/udeb/simple_test_manual.exe",
		"$(EPOCROOT)/epoc32/include/testexportheader.h",
		"$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv7.auto.bat",
		"$(EPOCROOT)/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv7.manual.bat"
		]
	t.mustmatch = [".*/epoc32/data/z/test/smoke_suite_test_resources_simple_test/armv7.auto.bat</build>.*"]
	t.run()
	return t
Пример #30
0
def run():
	t = SmokeTest()
	t.name = "badconfigs"

	t.description = """Tests that Raptor does indicate errors but does not traceback when reading faulty config files"""
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf --configpath=test/smoke_suite/test_resources/badconfigs --export-only -n -m ${SBSMAKEFILE} -f ${SBSLOGFILE}"
	t.mustmatch = [
		"sbs: warning: Failed to read XML file: .*missing_model_close_tag.xml:14:3: mismatched tag.*",
		"sbs: warning: Failed to read XML file: .*missing_build_close.xml:18:0: no element found.*",
		"sbs: warning: Unknown element bset.*",
		"sbs: warning: Failed to read XML file: .*testconfig.xml:17:2: mismatched tag.*",
		"sbs: warning: Unknown element bset.*",
		"sbs: warning: Failed to read XML file: .*uknowntag.xml:17:2: mismatched tag.*",
		"sbs: warning: Failed to read XML file:.*notxml1.xml:1:5:.*"
	]
	t.warnings = 7
	t.errors = 0
	t.returncode=0
	t.run()

	return t
Пример #31
0
def run():
	t = SmokeTest()
	t.name = "make_engine_filenames"
	t.description = "Can we pass the makefilename and stage name to emake options like --annofile etc?"
	
	t.mustmatch = [	".*Executing.*emake.*historyfile=.*default\.history.*",
			".*Executing.*emake.*annofile=.*\.default\.anno.*"]

	t.mustnotmatch = [".*Executing.*emake.*historyfile=.*#STAGE#\.history.*",
			  ".*Executing.*emake.*annofile=#MAKEFILE#\.anno.*"]
	
	t.usebash = True
	t.errors = 1
	t.returncode = 1
	base_command = "sbs generate -b smoke_suite/test_resources/simple/bld.inf -f-"
	
	t.command = base_command + " -e emake --mo=--emake-annofile=#MAKEFILE#.anno --mo=--emake-historyfile=$(EPOCROOT)/epoc32/build/#STAGE#.history -k NOTARGET"
	t.run()
		
	t.print_result()
	return t
Пример #32
0
def run():
    t = SmokeTest()
    t.name = "badconfigs"

    t.description = """Tests that Raptor does indicate errors but does not traceback when reading faulty config files"""
    t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf --configpath=test/smoke_suite/test_resources/badconfigs --export-only -n -m ${SBSMAKEFILE} -f ${SBSLOGFILE}"
    t.mustmatch = [
        "sbs: warning: Failed to read XML file: .*missing_model_close_tag.xml:14:3: mismatched tag.*",
        "sbs: warning: Failed to read XML file: .*missing_build_close.xml:18:0: no element found.*",
        "sbs: warning: Unknown element bset.*",
        "sbs: warning: Failed to read XML file: .*testconfig.xml:17:2: mismatched tag.*",
        "sbs: warning: Unknown element bset.*",
        "sbs: warning: Failed to read XML file: .*uknowntag.xml:17:2: mismatched tag.*",
        "sbs: warning: Failed to read XML file:.*notxml1.xml:1:5:.*"
    ]
    t.warnings = 7
    t.errors = 0
    t.returncode = 0
    t.run()

    return t
Пример #33
0
def run():
	t = SmokeTest()
	t.id = "29"
	t.name = "armv7_testcode"
	t.command = "sbs -b smoke_suite/test_resources/simple_test/bld.inf -c " + \
			"armv7.test -f - "
	
	# Don't allow -f to be appended
	t.logfileOption = lambda :""
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv7/urel/simple_test_auto.exe",
		"$(EPOCROOT)/epoc32/release/armv7/urel/simple_test_manual.exe",
		"$(EPOCROOT)/epoc32/release/armv7/udeb/simple_test_auto.exe",
		"$(EPOCROOT)/epoc32/release/armv7/udeb/simple_test_manual.exe",
		"$(EPOCROOT)/epoc32/include/testexportheader.h",
		"$(EPOCROOT)/epoc32/data/z/test/simple_test/armv7.auto.bat",
		"$(EPOCROOT)/epoc32/data/z/test/simple_test/armv7.manual.bat"
		]
	t.mustmatch = [".*/epoc32/data/z/test/simple_test/armv7.auto.bat</build>.*"]
	t.run()
	return t
Пример #34
0
def run():
    t = SmokeTest()
    t.id = "33"
    t.name = "exe_winscw"
    t.usebash = True
    t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c winscw -m ${SBSMAKEFILE} -f ${SBSLOGFILE}; grep -E \"mwldsym2\" ${SBSLOGFILE}"
    t.targets = [
        "$(EPOCROOT)/epoc32/release/winscw/udeb/test.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/test.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/test.exe.map"
    ]
    t.addbuildtargets('smoke_suite/test_resources/simple/bld.inf', [
        "test_/winscw/udeb/test.o", "test_/winscw/udeb/test_.o",
        "test_/winscw/udeb/test_UID_.o", "test_/winscw/udeb/test.UID.CPP",
        "test_/winscw/urel/test.o", "test_/winscw/urel/test_.o",
        "test_/winscw/urel/test_UID_.o", "test_/winscw/urel/test.UID.CPP"
    ])
    # Check that the default operator new library is used
    t.mustmatch = ['.*mwldsym2.*scppnwdl.lib.*test.exe.*']
    t.run()
    return t
Пример #35
0
def run():
    t = SmokeTest()
    t.usebash = True

    if "SBS_ELF2E32" in os.environ:
        elf2e32 = os.environ["SBS_ELF2E32"]
    elif sys.platform.startswith("win"):
        elf2e32 = "$(EPOCROOT)/epoc32/tools/elf2e32.exe"
    else:
        elf2e32 = "$(EPOCROOT)/epoc32/tools/elf2e32"

    description = """This test attempts to check that an exe gets the capabilities that we requested.  It's ARM specific since it uses elf2e32. Tries to demonstrate capabilties being turned off then on in the mmp."""
    command = "sbs -b smoke_suite/test_resources/simple/capability.inf -c {0} -m ${{SBSMAKEFILE}} -f ${{SBSLOGFILE}} && " + \
        elf2e32 + " --dump=s  --e32input=$(EPOCROOT)/epoc32/release/armv5/urel/test_capability.exe"
    targets = [
        "$(EPOCROOT)/epoc32/release/armv5/urel/test_capability.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/test_capability.exe.map"
    ]
    buildtargets = []
    mustmatch = [
        "\s*Secure ID: 10003a5c$", "\s*Vendor ID: 00000000$",
        "\s*Capabilities: 00000000 000fffbf$", "\s*CommDD$", "\s*PowerMgmt$",
        "\s*MultimediaDD$", "\s*ReadDeviceData$", "\s*WriteDeviceData$",
        "\s*TrustedUI$", "\s*DiskAdmin$", "\s*NetworkControl$", "\s*AllFiles$",
        "\s*SwEvent$", "\s*NetworkServices$", "\s*LocalServices$",
        "\s*ReadUserData$", "\s*WriteUserData$", "\s*Location$",
        "\s*SurroundingsDD$", "\s*UserEnvironment$", "\s*TCB$"
    ]
    mustnotmatch = ["DRM"]
    warnings = 0

    t.name = "capability_arm"
    t.description = description
    t.command = command.format("arm.v5.urel.gcce4_4_1")
    t.targets = targets
    t.mustmatch = mustmatch
    t.mustnotmatch = mustnotmatch
    t.warnings = warnings
    t.run()
    return t
Пример #36
0
def run():
    t = SmokeTest()
    t.id = "85a"
    t.name = "commandline_nodefaults"
    t.description = """Test that raptor complains if you run it without specifying any components and there is no default bld.inf or system definition in the current directory."""
    t.usebash = True

    t.command = """
		TMPDIR="build/commandline_testdefaults";
		cd $(EPOCROOT)/epoc32 && rm -rf "$TMPDIR" 2>/dev/null; mkdir -p "$TMPDIR" && cd "$TMPDIR" &&
		sbs ${SBSLOGFILE} -n ; rm -rf "$TMPDIR"
	"""

    t.mustmatch = [
        ".*warning: No default bld.inf or system definition.*found.* "
    ]
    t.warnings = 1
    t.run()

    t.id = "0085"
    t.name = "commandline"
    return t
def run():
	t = SmokeTest()

	t.name = "sbs_with_nonexisting_bldinf"
	t.description = "Test if sbs generates warning if invoked without bld.inf specified i.e. using default bld.inf which doesn't exist"
	t.command = "mkdir ${EPOCROOT}/emptydir; rm ${EPOCROOT}/emptydir/*;  cd ${EPOCROOT}/emptydir; sbs -f ${SBSLOGFILE} -m {SBSMAKEFILE}"
	t.usebash = True
	t.warnings = 1 
	t.run()
	
	t.name = "sbs_with_nonexisting_bldinf_cli"
	t.description = "Test if sbs generates an error if invoked with a bad -b option"
	t.command = "sbs -b none.inf"
	t.usebash = False
	t.errors = 1
	t.warnings = 0
	t.returncode = 1
	t.mustmatch = ["sbs: error: build info file does not exist \(component .*none.inf\)"] 
	t.run()
	
	t.print_result()
	return t
Пример #38
0
def run():
	t = SmokeTest()
	t.name="bad_config"

	t.description = """Checks that if you give an incomplete (unbuildable) configuration that raptor complains nicely without a traceback."""
	
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c arm.v5.rvct4_0 -c arm.v5.rvct2_2" # missing "urel" or "udeb"
	t.targets = [
		]	
	t.mustmatch = [
	"sbs: error: arm.v5.rvct2_2 is a bad configuration: Unset variable '.*' used in spec 'none' with config 'none'",
	"sbs: error: arm.v5.rvct4_0 is a bad configuration: Unset variable '.*' used in spec 'none' with config 'none'",
	"sbs: error: Build stopped because the following requested configurations are incomplete or invalid: arm.v5.rvct2_2, arm.v5.rvct4_0"
	]
	t.mustnotmatch = [
		".*Traceback.*",
		".*UninitialisedVariableException.*"
	]
	t.errors = 3
	t.returncode = 1
	
	t.run()
	return t
Пример #39
0
def run():
    t = SmokeTest()
    t.usebash = True

    t.description = "Test that a timing log is created and contains total parse and build durations"

    t.id = "0103b"
    t.name = "timing_on"
    t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf" + \
      " --filters=FilterLogfile,FilterTiming -f ${SBSLOGFILE} && " + \
      "grep progress:duration ${SBSLOGFILE}.timings"
    t.mustmatch = [
        "^<progress:duration object_type='layer' task='parse' key='.*' duration='\d+.\d+' />$",
        "^<progress:duration object_type='layer' task='build' key='.*' duration='\d+.\d+' />$",
        "^<progress:duration object_type='all' task='all' key='all' duration='\d+.\d+' />$"
    ]
    t.mustnotmatch = []
    t.run()

    t.id = "103"
    t.name = "timing"
    t.print_result()

    return t
Пример #40
0
def run():
	t = SmokeTest()
	t.id = "8"
	t.name = "bitmap"
	t.description = "This step is for testing BITMAP keyword and MIFCONV support for s60"
	t.usebash = True
	t.command = "sbs -b smoke_suite/test_resources/bitmap/bld.inf BITMAP && grep -ir 'MIFCONV_TEST:=1' $(EPOCROOT)/epoc32/build"
	t.targets = [
		"$(EPOCROOT)/epoc32/include/testbitmap.mbg",
		"$(EPOCROOT)/epoc32/data/z/resource/apps/testbitmap.mBm",
		"$(EPOCROOT)/epoc32/tools/makefile_templates/test/mifconv.xml",
		"$(EPOCROOT)/epoc32/tools/makefile_templates/test/mifconv.flm"
		]
	t.addbuildtargets('smoke_suite/test_resources/bitmap/bld.inf', [
		"testbitmap_dll/testbitmap.mBm_bmconvcommands"
	])
	t.mustmatch = [
		".*Makefile(_all)?.bitmap:MIFCONV_TEST:=1.*"
	]
	t.mustnotmatch = [
		".*Makefile(_all)?.default:MIFCONV_TEST.*"
	]
	t.run()
	return t
def run():
    t = SmokeTest()

    t.name = "sbs_with_nonexisting_bldinf"
    t.description = "Test if sbs generates warning if invoked without bld.inf specified i.e. using default bld.inf which doesn't exist"
    t.command = "mkdir ${EPOCROOT}/emptydir; rm ${EPOCROOT}/emptydir/*;  cd ${EPOCROOT}/emptydir; sbs -f ${SBSLOGFILE} -m {SBSMAKEFILE}"
    t.usebash = True
    t.warnings = 1
    t.run()

    t.name = "sbs_with_nonexisting_bldinf_cli"
    t.description = "Test if sbs generates an error if invoked with a bad -b option"
    t.command = "sbs -b none.inf"
    t.usebash = False
    t.errors = 1
    t.warnings = 0
    t.returncode = 1
    t.mustmatch = [
        "sbs: error: build info file does not exist \(component .*none.inf\)"
    ]
    t.run()

    t.print_result()
    return t
Пример #42
0
def run():
	t = SmokeTest()
	t.id = "39"
	t.name = "openenvironment"
	t.description = """Test STDEXE, STDLIB and STDDLL creation; Test open environment project linking against a symbian environment
		library; Test symbian environment project linking against an open environment library"""
	t.usebash = True
	t.command = "sbs -k -b smoke_suite/test_resources/oe/group/bld.inf -c armv5 -c winscw " + \
		"-m ${SBSMAKEFILE} -f ${SBSLOGFILE}; grep -E \"(armlink|checklib|mwldsym2)\" ${SBSLOGFILE}"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oedll.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/symbian_test.lib",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oeexe.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oelib.lib",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oeexe.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oeexe.exe.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oedll.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oedll.dll.sym",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/symbian_test.lib",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oeexe.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oelib.lib",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oeexe.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oeexe.exe.sym",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oedll.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/lib/t_oedll.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/t_oedll{000a0000}.dso",
		"$(EPOCROOT)/epoc32/release/winscw/urel/symbian_test.lib",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oedll.dll",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oeexe.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oelib.lib",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oeexe.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oedll.dll.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/symbian_test.lib",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_oedll.lib",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_oedll.dll",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_oelib.lib"
		]
	t.addbuildtargets('smoke_suite/test_resources/oe/group/bld.inf', [
		"t_oedll_dll/armv5/urel/t_oedll{000a0000}.dso",
		"t_oedll_dll/armv5/urel/t_oedll_urel_objects.via",
		"t_oedll_dll/armv5/urel/t_oedll.o",
		"t_oedll_dll/armv5/urel/t_oedll.o.d",
                # either prep file can exist - luck determines which
                 ['t_oedll_dll/armv5/urel/t_oedll.prep',
                  't_oedll_dll/armv5/udeb/t_oedll.prep'],
		"t_oedll_dll/armv5/urel/t_oedll{000a0000}.def",
		"t_oedll_dll/armv5/udeb/t_oedll{000a0000}.dso",
		"t_oedll_dll/armv5/udeb/t_oedll_udeb_objects.via",
		"t_oedll_dll/armv5/udeb/t_oedll.o",
		"t_oedll_dll/armv5/udeb/t_oedll.o.d",
		"t_oedll_dll/armv5/udeb/t_oedll{000a0000}.def",
		"symbian_test_lib/armv5/urel/symbian_test_urel_objects.via",
		"symbian_test_lib/armv5/urel/symbian_lib.o.d",
		"symbian_test_lib/armv5/urel/symbian_lib.o",
		"symbian_test_lib/armv5/udeb/symbian_test_udeb_objects.via",
		"symbian_test_lib/armv5/udeb/symbian_lib.o.d",
		"symbian_test_lib/armv5/udeb/symbian_lib.o",
		"wrong_newlib_test_oeexe_exe/armv5/urel/wrong_newlib_test_oeexe_urel_objects.via",
		"wrong_newlib_test_oeexe_exe/armv5/urel/t_oeexe.o",
		"wrong_newlib_test_oeexe_exe/armv5/urel/t_oeexe.o.d",
		"wrong_newlib_test_oeexe_exe/armv5/udeb/t_oeexe.o",
		"wrong_newlib_test_oeexe_exe/armv5/udeb/wrong_newlib_test_oeexe_udeb_objects.via",
		"wrong_newlib_test_oeexe_exe/armv5/udeb/t_oeexe.o.d",
		"wrong_newlib_seexe_exe/armv5/urel/wrong_newlib_seexe_urel_objects.via",
		"wrong_newlib_seexe_exe/armv5/urel/wrong_newlib_symbian.o",
		"wrong_newlib_seexe_exe/armv5/urel/wrong_newlib_symbian.o.d",
		"wrong_newlib_seexe_exe/armv5/udeb/wrong_newlib_seexe_udeb_objects.via",
		"wrong_newlib_seexe_exe/armv5/udeb/wrong_newlib_symbian.o",
		"wrong_newlib_seexe_exe/armv5/udeb/wrong_newlib_symbian.o.d",
		"t_oeexe_exe/armv5/urel/t_oeexe_urel_objects.via",
		"t_oeexe_exe/armv5/urel/t_oeexe.o",
		"t_oeexe_exe/armv5/urel/t_oeexe.o.d",
		"t_oeexe_exe/armv5/udeb/t_oeexe.o",
		"t_oeexe_exe/armv5/udeb/t_oeexe.o.d",
		"t_oeexe_exe/armv5/udeb/t_oeexe_udeb_objects.via",
		"t_oelib_lib/armv5/urel/t_oelib_urel_objects.via",
		"t_oelib_lib/armv5/urel/t_oelib.o",
		"t_oelib_lib/armv5/urel/t_oelib.o.d",
		"t_oelib_lib/armv5/udeb/t_oelib.o",
		"t_oelib_lib/armv5/udeb/t_oelib_udeb_objects.via",
		"t_oelib_lib/armv5/udeb/t_oelib.o.d",
		"t_oedll_dll/winscw/urel/t_oedll.dep",
		"t_oedll_dll/winscw/urel/t_oedll.lib",
		"t_oedll_dll/winscw/urel/t_oedll_SYM_.cpp",
		"t_oedll_dll/winscw/urel/t_oedll.dll",
		"t_oedll_dll/winscw/urel/t_oedll_UID_.o",
		"t_oedll_dll/winscw/urel/t_oedll_SYM_.o",
		"t_oedll_dll/winscw/urel/t_oedll.o",
		"t_oedll_dll/winscw/urel/t_oedll_UID_.o.d",
		"t_oedll_dll/winscw/urel/t_oedll.o.d",
		"t_oedll_dll/winscw/urel/t_oedll_UID_.dep",
		"t_oedll_dll/winscw/urel/t_oedll.sym",
		"t_oedll_dll/winscw/urel/t_oedll.UID.CPP",
		"t_oedll_dll/winscw/urel/t_oedll_SYM_.o.d",
		"t_oedll_dll/winscw/urel/t_oedll_SYM_.dep",
                # The prep.def file can be in urel or udeb
                ['t_oedll_dll/winscw/urel/t_oedll.prep.def',
                 't_oedll_dll/winscw/udeb/t_oedll.prep.def'],
		"t_oedll_dll/winscw/urel/t_oedll.def",
		"t_oedll_dll/winscw/urel/t_oedll.inf",
		"t_oedll_dll/winscw/udeb/t_oedll.dep",
		"t_oedll_dll/winscw/udeb/t_oedll.lib",
		"t_oedll_dll/winscw/udeb/t_oedll_SYM_.cpp",
		"t_oedll_dll/winscw/udeb/t_oedll.dll",
		"t_oedll_dll/winscw/udeb/t_oedll_UID_.o",
		"t_oedll_dll/winscw/udeb/t_oedll_SYM_.o",
		"t_oedll_dll/winscw/udeb/t_oedll.o",
		"t_oedll_dll/winscw/udeb/t_oedll_UID_.o.d",
		"t_oedll_dll/winscw/udeb/t_oedll.o.d",
		"t_oedll_dll/winscw/udeb/t_oedll_UID_.dep",
		"t_oedll_dll/winscw/udeb/t_oedll.sym",
		"t_oedll_dll/winscw/udeb/t_oedll.UID.CPP",
		"t_oedll_dll/winscw/udeb/t_oedll_SYM_.o.d",
		"t_oedll_dll/winscw/udeb/t_oedll_SYM_.dep",
		"t_oedll_dll/winscw/udeb/t_oedll.def",
		"t_oedll_dll/winscw/udeb/t_oedll.inf",
		"symbian_test_lib/winscw/urel/symbian_lib.dep",
		"symbian_test_lib/winscw/urel/symbian_lib.o.d",
		"symbian_test_lib/winscw/urel/symbian_lib.o",
		"symbian_test_lib/winscw/udeb/symbian_lib.dep",
		"symbian_test_lib/winscw/udeb/symbian_lib.o.d",
		"symbian_test_lib/winscw/udeb/symbian_lib.o",
		"wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe_UID_.dep",
		"wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe_UID_.o.d",
		"wrong_newlib_test_oeexe_exe/winscw/urel/t_oeexe_wins.dep",
		"wrong_newlib_test_oeexe_exe/winscw/urel/t_oeexe_wins.o",
		"wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe.UID.CPP",
		"wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe_UID_.o",
		"wrong_newlib_test_oeexe_exe/winscw/urel/t_oeexe_wins.o.d",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe_UID_.dep",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe_UID_.o.d",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/t_oeexe_wins.dep",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/t_oeexe_wins.o",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe.UID.CPP",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe_UID_.o",
		"wrong_newlib_test_oeexe_exe/winscw/udeb/t_oeexe_wins.o.d",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe_UID_.dep",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe_UID_.o",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_symbian.dep",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_symbian.o",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_symbian.o.d",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe.UID.CPP",
		"wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe_UID_.o.d",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe_UID_.dep",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe_UID_.o",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_symbian.dep",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_symbian.o",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_symbian.o.d",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe.UID.CPP",
		"wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe_UID_.o.d",
		"t_oeexe_exe/winscw/urel/t_oeexe_UID_.o",
		"t_oeexe_exe/winscw/urel/t_oeexe_UID_.dep",
		"t_oeexe_exe/winscw/urel/t_oeexe_wins.dep",
		"t_oeexe_exe/winscw/urel/t_oeexe_wins.o",
		"t_oeexe_exe/winscw/urel/t_oeexe_UID_.o.d",
		"t_oeexe_exe/winscw/urel/t_oeexe.UID.CPP",
		"t_oeexe_exe/winscw/urel/t_oeexe_wins.o.d",
		"t_oeexe_exe/winscw/udeb/t_oeexe_UID_.o",
		"t_oeexe_exe/winscw/udeb/t_oeexe_UID_.dep",
		"t_oeexe_exe/winscw/udeb/t_oeexe_wins.dep",
		"t_oeexe_exe/winscw/udeb/t_oeexe_wins.o",
		"t_oeexe_exe/winscw/udeb/t_oeexe_UID_.o.d",
		"t_oeexe_exe/winscw/udeb/t_oeexe.UID.CPP",
		"t_oeexe_exe/winscw/udeb/t_oeexe_wins.o.d",
		"t_oelib_lib/winscw/urel/t_oelib.o",
		"t_oelib_lib/winscw/urel/t_oelib.o.d",
		"t_oelib_lib/winscw/urel/t_oelib.dep",
		"t_oelib_lib/winscw/udeb/t_oelib.o",
		"t_oelib_lib/winscw/udeb/t_oelib.o.d",
		"t_oelib_lib/winscw/udeb/t_oelib.dep"
	])
	
	# On 9.4 the open environment checks for
	# mixed symbianc++ and stdc++ new/delete won't fail
	if getsymbianversion() != "9.4":
		t.mustmatch = [
			'.*checklib: error: library .*epoc32.release.armv5.urel.symbian_test.lib is incompatible with standard.*',
			'.*checklib: error: library .*epoc32.release.armv5.urel.t_oelib.lib is incompatible with Symbian.*',
			'.*checklib: error: library .*epoc32.release.armv5.udeb.symbian_test.lib is incompatible with standard.*',
			'.*checklib: error: library .*epoc32.release.armv5.udeb.t_oelib.lib is incompatible with Symbian.*',
			'.*checklib: error: library .*epoc32.release.winscw.urel.symbian_test.lib is incompatible with standard.*',
			'.*checklib: error: library .*epoc32.release.winscw.urel.t_oelib.lib is incompatible with Symbian.*',
			'.*checklib: error: library .*epoc32.release.winscw.udeb.t_oelib.lib is incompatible with Symbian.*',
			'.*checklib: error: library .*epoc32.release.winscw.udeb.symbian_test.lib is incompatible with standard.*',
			'.*armlink.*oe_exe_without_stdcpp.*scppnwdl.dso.*',
			'.*armlink.*symbian_exe_with_stdcpp.*stdnew.dso.*',
			'.*armlink.*oedll.*stdnew.dso.*',
			'.*armlink.*oeexe.*stdnew.dso.*',
			'.*armlink.*symbian_newlib.exe.*scppnwdl.dso.*'
		]
		t.mustnotmatch = [
			'.*armlink.*oe_exe_without_stdcpp.*stdnew.dso.*',
			'.*armlink.*symbian_exe_with_stdcpp.*scppnwdl.dso.*',
			'.*armlink.*oedll.*scppnwdl.dso.*',
			'.*armlink.*oeexe.*scppnwdl.dso.*',
			'.*armlink.*symbian_newlib.exe.*stdnew.dso.*',
			'.*mwldsym2.*scppnwdl.lib.*symbian_exe_with_stdcpp.exe.*'
		]
	else: 
		# these files will build for 9.4
		t.targets.extend([
			"$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_oeexe.exe",
			"$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_oeexe.exe.map",
			"$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_oeexe.exe",
			"$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_oeexe.exe.map",
			"$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_seexe.exe",
			"$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_seexe.exe.map",
			"$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_seexe.exe",
			"$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_seexe.exe.map",
			"$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_oeexe.exe",
			"$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_oeexe.exe",
			"$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_seexe.exe",
			"$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_seexe.exe",
			"$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_oeexe.exe.map",
			"$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_oeexe.exe.map",
			"$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_seexe.exe.map",
			"$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_seexe.exe.map",
			"$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_oeexe.exe.sym",
			"$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_oeexe.exe.sym",
			"$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_seexe.exe.sym",
			"$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_seexe.exe.sym"
		])
	t.run()
	return t
Пример #43
0
def run():
	t = SmokeTest()
	t.id = "0092a"
	t.name = "toolcheck"
	t.description = """Test toolcheck works properly, with 3 options: on, off and forced. 
				TOOL1 3 4 and 5 are expected to fail and 2 to pass"""
	result = SmokeTest.PASS
	toolcheckDir = os.environ["SBS_HOME"].replace("\\","/") + "/test/smoke_suite/test_resources/toolcheck"

	# toolcheck ON
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -n --configpath=" + toolcheckDir + \
			" -c default.toolcheck --toolcheck=on"
	
	t.mustmatch = [
		".*tool 'TOOLCHECK1' from config 'none' did not return version.*",
		".*tool 'TOOLCHECK3' from config 'none' did not return version.*",
		".*tool 'TOOLCHECK4' from config 'none' did not return version.*",
		".*tool 'TOOLCHECK5' from config 'none' did not return version.*"
		]
	t.mustnotmatch = [
		".*TOOLCHECK2.*",
		".*TOOLCHECK6.*"
		]
	t.errors = 4
	t.returncode = 1
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL

	# toolcheck OFF
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -n --configpath=" + toolcheckDir + \
			" -c default.toolcheck --toolcheck=off"

	t.id = "0092b"
	t.mustmatch = []
	t.mustnotmatch = [
		".*TOOLCHECK1.*",
		".*TOOLCHECK3.*",
		".*TOOLCHECK4.*",
		".*TOOLCHECK5.*",
		".*TOOLCHECK6.*"
		]
	t.errors = 0
	t.returncode = 0
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL

	# force toolcheck
	t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -n --configpath=" + toolcheckDir + \
			" -c default.toolcheck --toolcheck=forced"

	t.id = "0092c"
	t.mustmatch = [
		".*tool 'TOOLCHECK1' from config 'none' did not return version.*",
		".*tool 'TOOLCHECK3' from config 'none' did not return version.*",
		".*tool 'TOOLCHECK4' from config 'none' did not return version.*",
		".*tool 'TOOLCHECK5' from config 'none' did not return version.*"
		]
	t.mustnotmatch = [
		".*TOOLCHECK2.*",
		".*TOOLCHECK6.*"
	]
	t.errors = 4
	t.returncode = 1
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL


	t.id = "0092"
	t.result = result
	t.print_result()
	return t
Пример #44
0
def run():
	t = SmokeTest()
	t.usebash = True
	result = SmokeTest.PASS

	description = "Validates the --no-metadata-depend option"

	base_command = "sbs -b smoke_suite/test_resources/simple/bld.inf"

	targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test.exe.sym",
		]

	buildtargets = [
		"test_/armv5/urel/test.o",
		"test_/armv5/urel/test.o.d",
		"test_/armv5/urel/test3.o.d",
		"test_/armv5/urel/test4.o.d",
		"test_/armv5/urel/test5.o.d",
		"test_/armv5/urel/test1.o.d",
		"test_/armv5/urel/test6.o.d",
		"test_/armv5/urel/test2.o.d",
		"test_/armv5/urel/test3.o",
		"test_/armv5/urel/test4.o",
		"test_/armv5/urel/test5.o",
		"test_/armv5/urel/test1.o",
		"test_/armv5/urel/test6.o",
		"test_/armv5/urel/test2.o",
		"test_/armv5/urel/test_.o",
		"test_/armv5/urel/test_urel_objects.via"
		]

	mustmatch = [
	]
	
	# Initial build of simple.exe to get all the files in place
	t.name = "initial_build"
	t.description = "Initial build"
	t.command = "{0} -c arm.v5.urel.gcce4_4_1".format(base_command)
	t.targets = targets
	t.addbuildtargets("smoke_suite/test_resources/simple/bld.inf", buildtargets)
	t.mustmatch = [	"compile.*smoke_suite.test_resources.simple.test.cpp.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test.cia.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test1.c\+\+.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test2.cxx.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test3.Cpp.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test4.cc.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test5.CC.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test6.C\+\+.*\[arm.v5.urel.gcce4_4_1\]",
					"target.*epoc32.release.armv5.urel.test.exe.*\[arm.v5.urel.gcce4_4_1\]"
					]
	t.run()
	
	# Rebuild using the --no-metadata-depend option having touched the MMP
	# No build should happen.
	t.name = "rebuild_with_using_no_metadata_depend"
	t.description = "Touch an MMP and run build again using --no-metadata-depend"
	t.command = ("touch smoke_suite/test_resources/simple/simple.mmp; " +
				"{0} -c arm.v5.urel.gcce4_4_1 --no-metadata-depend ".format(base_command))
	t.targets = targets
	t.addbuildtargets("smoke_suite/test_resources/simple/bld.inf", buildtargets)
	t.mustmatch = [	"no warnings or errors",
					"built 'arm.v5.urel.gcce4_4_1'"
					]
	# Don't clean the build targets as that would force a rebuild of everything.
	# The aim is to validate that nothing gets rebuilt despite the fact that the
	# MMP might have been re-written
	t.run(noclean=True)
	
	# Rebuild using the --no-metadata-depend option having touched the MMP
	# No build should happen.
	t.name = "rebuild_without_using_no_metadata_depend"
	t.description = "Touch an MMP and run build again without using --no-metadata-depend"
	t.command = ("touch smoke_suite/test_resources/simple/simple.mmp; " +
				"{0} -c arm.v5.urel.gcce4_4_1".format(base_command))
	t.targets = targets
	t.addbuildtargets("smoke_suite/test_resources/simple/bld.inf", buildtargets)
	t.mustmatch = [	"compile.*smoke_suite.test_resources.simple.test.cpp.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test.cia.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test1.c\+\+.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test2.cxx.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test3.Cpp.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test4.cc.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test5.CC.*\[arm.v5.urel.gcce4_4_1\]",
					"compile.*smoke_suite.test_resources.simple.test6.C\+\+.*\[arm.v5.urel.gcce4_4_1\]",
					"target.*epoc32.release.armv5.urel.test.exe.*\[arm.v5.urel.gcce4_4_1\]"
					]
	
	# Don't clean the build targets as that would force a rebuild of everything. 
	# The aim is to validate the dependency of the .exe on its mmp file, so 
	# a "touch" on the MMP, forces a rebuild
	t.run(noclean=True)
	
	return t
Пример #45
0
def run():
    result = SmokeTest.PASS
    t = SmokeTest()
    t.id = "0018a"
    t.name = "temclean"
    t.command = "sbs -b smoke_suite/test_resources/tem/bldclean.inf -c armv5 CLEAN"
    t.targets = [
        "$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded",
        "$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
    ]
    t.missing = 2
    t.warnings = 1
    t.returncode = 0
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.id = "0018b"
    t.name = "temtest"
    t.command = "sbs -b smoke_suite/test_resources/tem/bld.inf -c armv5"
    t.targets = ["$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded"]
    t.warnings = 2
    t.missing = 0
    t.returncode = 1
    t.mustmatch = ["repeated call to TEM with same values.* Stop\."]
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.id = "0018c"
    t.name = "temclean2"
    t.command = "sbs -b smoke_suite/test_resources/tem/bldclean.inf -c armv5 CLEAN"
    t.targets = [
        "$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded",
        "$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
    ]
    t.missing = 2
    t.warnings = 1
    t.returncode = 0
    t.mustmatch = []
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.id = "0018d"
    t.name = "badtem"
    t.command = "sbs -b smoke_suite/test_resources/tem/bad_bld.inf -c armv5"
    t.targets = ["$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"]
    t.warnings = 3
    t.missing = 0
    t.returncode = 1
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.id = "0018e"
    t.name = "temclean3"
    t.command = "sbs -b smoke_suite/test_resources/tem/bldclean.inf -c armv5 CLEAN"
    t.targets = [
        "$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded",
        "$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
    ]
    t.missing = 2
    t.warnings = 1
    t.returncode = 0
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t = CheckWhatSmokeTest()
    t.id = "0018f"
    t.name = "temwhat"
    t.command = "sbs -b smoke_suite/test_resources/simple_extension/bld.inf --what"
    t.output_expected_only_once = True
    t.stdout = [
        # exports
        '$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/clean.mk',
        '$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/clean.meta',
        '$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/build.mk',
        '$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/build.meta',
        # release tree built
        '$(EPOCROOT)/epoc32/release/armv5/udeb/simple_extension.txt',
        '$(EPOCROOT)/epoc32/release/armv5/urel/simple_extension.txt',
        '$(EPOCROOT)/epoc32/release/winscw/udeb/simple_extension.txt',
        '$(EPOCROOT)/epoc32/release/winscw/urel/simple_extension.txt'
    ]
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t = SmokeTest()
    t.id = "0018g"
    t.name = "badtem2"
    t.command = "sbs -b smoke_suite/test_resources/tem/bad2_bld.inf -c armv5"
    t.targets = ["$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"]
    t.warnings = 3
    t.returncode = 1
    t.run()
    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    t.id = "18"
    t.name = "temtest"
    t.result = result
    t.print_result()
    return t
Пример #46
0
def run():
	t = SmokeTest()
	t.description = """
		Tests the creation and content of an .iby romfile 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 :""
	
	t.id = "55a"
	# Check content of iby file is correct
	# Check 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} " \
			+ "&& cat $(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5test.iby"
	
	t.targets = [
		"$(EPOCROOT)/epoc32/rom/src/ongoing/group/romfile/armv5test.iby",
		"$(EPOCROOT)/epoc32/data/z/test/src/armv5.auto.bat",
		"$(EPOCROOT)/epoc32/data/z/test/src/armv5.manual.bat"
		]

	# Check the content of the generated .iby file.
	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/armv5\.auto\.bat test/src\.auto\.bat\n.*",
		r".*\ndata=/epoc32/data/z/test/src/armv5\.manual\.bat test/src\.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 paged\n.*",
		r".*\nfile=/epoc32/release/##MAIN##/##BUILD##/t_fsys\.exe\s+sys/bin/t_fsys\.exe unpaged\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.*"
		]
	t.mustnotmatch = [
		# Try to detect file paths that contain two or more slashes in a row,
		# without flagging C++ style comments.
		r"\w//+\w"
		]
	t.warnings = 0 if t.onWindows else 2
	t.run()
	

	t.id = "55b"
	# t.targets and t.warnings are the same as above and thus omitted
	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/data/z/test/src/armv5.auto.bat</build>.*",
		r".*/epoc32/data/z/test/src/armv5.manual.bat</build>.*"
		]
	t.mustnotmatch = []
	t.run()


	t.id = "55c"
	t.name = "romfile_mmp_include_twice"
	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} " \
			+ "&& cat $(EPOCROOT)/epoc32/rom/src/e32test/group/armv5test.iby"
	
	t.targets = [
		"$(EPOCROOT)/epoc32/rom/src/e32test/group/armv5test.iby"
		]

	# Check the content of the generated .iby file
	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.id = "55"
	t.name = "romfile"
	t.print_result()
	return t
Пример #47
0
def run():
	t = SmokeTest()
	t.description = "This testcase tests all mmp keywords including new implementation of 'paged/unpaged code/data'"
	t.usebash = True
	
	t.id = "75a"
	t.name = "mmp_1"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp1/group/bld.inf -c armv5 -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/shutdownsrv.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/shutdownsrv.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/shutdownsrv.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/shutdownsrv.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/lib/exportlibrary_shutdownsrv.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/exportlibrary_shutdownsrv{000a0000}.dso",
	]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp1/group/bld.inf", [
		"shutdownsrv_dll/armv5/udeb/shutdownsrv.o",
		"shutdownsrv_dll/armv5/urel/shutdownsrv.o",
		"shutdownsrv_dll/armv5/udeb/shutdownsrvpatchdata.o",
		"shutdownsrv_dll/armv5/urel/shutdownsrvpatchdata.o",
		"shutdownsrv_dll/armv5/udeb/shutdowntimer.o",
		"shutdownsrv_dll/armv5/urel/shutdowntimer.o"
		])
	t.mustmatch = [
		".*elf2e32.*(--defaultpaged|--codepaging=default.*--datapaging=default).*",
		".*armlink.*--verbose.*"
	]
	t.run()

	t.id = "75b"
	t.name = "mmp_2"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp2/group/bld.inf -c armv5 -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/imageprocessorperf.lib",
		"$(EPOCROOT)/epoc32/release/armv5/urel/imageprocessorperf.lib"		
	]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp2/group/bld.inf", [
		"imageprocessorperf_lib/armv5/udeb/ColorConverter.o",
		"imageprocessorperf_lib/armv5/urel/ColorConverter.o",
		"imageprocessorperf_lib/armv5/udeb/ImageProcessor.o",
		"imageprocessorperf_lib/armv5/urel/ImageProcessor.o"
		])
	t.mustmatch = [
		".*armcc.*-O0.*-g.*--cpu 6.*-Otime.*",
		".*armcc.*-O3.*--cpu 6.*-Otime.*",
		".*OPTION ARMASM has no effect.*",
		".*OPTION_REPLACE ARMASM has no effect.*"
	]
	t.mustnotmatch = [
		".*armcc.*--export_all_vtbl.*"
	]
	t.warnings = 2
	t.run()
	
	t.id = "75c"
	t.name = "mmp_3"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp3/bld.inf -c armv5 -c winscw -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/tbm.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/tbm.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/tbm.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/tbm.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oom.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oom.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oom.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oom.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/dfpaeabi_vfpv2.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/dfpaeabi_vfpv2.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/dfpaeabi_vfpv2.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/dfpaeabi_vfpv2.dll.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oom.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oom.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_oom.exe"
		]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp3/bld.inf", [
		"tbm_exe/armv5/udeb/tbm.o",
		"tbm_exe/armv5/urel/tbm.o",
		"t_oom_exe/armv5/udeb/t_oom.o",
		"t_oom_exe/armv5/urel/t_oom.o",
		"dfpaeabi_vfpv2_dll/armv5/udeb/dfpaeabi.o",
		"dfpaeabi_vfpv2_dll/armv5/urel/dfpaeabi.o",
		"t_oom_exe/winscw/udeb/t_oom.o",
		"t_oom_exe/winscw/udeb/t_oom_UID_.o",
		"t_oom_exe/winscw/urel/t_oom.o",
		"t_oom_exe/winscw/urel/t_oom_UID_.o"
		])
	t.mustmatch = [
		".*armlink.*udeb/eexe.lib.*-o.*armv5/udeb/t_oom.exe.sym.*euser.dso.*efsrv.dso.*estor.dso.*euser.dso.*",
		".*armlink.*urel/eexe.lib.*-o.*armv5/urel/t_oom.exe.sym.*euser.dso.*efsrv.dso.*euser.dso.*",
		".*mwldsym2.*udeb/eexe.lib.*euser.lib.*efsrv.lib.*estor.lib.*euser.lib.*-o.*winscw/udeb/t_oom.exe.*",
		".*mwldsym2.*urel/eexe.lib.*euser.lib.*efsrv.lib.*euser.lib.*-o.*winscw/urel/t_oom.exe.*"
		]
	t.mustnotmatch = []
	t.warnings = 0
	t.run()
	
	t.id = "75d"
	t.name = "mmp_4"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp4/group/bld.inf -c winscw"
	t.targets = [			
		"$(EPOCROOT)/epoc32/release/winscw/udeb/d_newldd.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/urel/d_newldd.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/d_lddturnaroundtimertest.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/urel/d_lddturnaroundtimertest.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/urel/d_lddturnaroundtimertest.ldd.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_sharedio3.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_sharedio3.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_sharedio3.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_rbuf.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_rbuf.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_rbuf.exe.map"
		]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp4/group/bld.inf", [
		"d_newldd_ldd/winscw/udeb/d_newldd.o",
		"d_newldd_ldd/winscw/udeb/d_newldd.UID.CPP",
		"d_newldd_ldd/winscw/udeb/d_newldd_UID_.o",
		"d_newldd_ldd/winscw/urel/d_newldd.o",
		"d_newldd_ldd/winscw/urel/d_newldd.UID.CPP",
		"d_newldd_ldd/winscw/urel/d_newldd_UID_.o",
		"d_newldd_ldd/winscw/udeb/t_new_classes.o",
		"d_newldd_ldd/winscw/urel/t_new_classes.o",
		"d_lddturnaroundtimertest_ldd/winscw/udeb/d_lddturnaroundtimertest.o",
		"d_lddturnaroundtimertest_ldd/winscw/udeb/d_lddturnaroundtimertest.UID.CPP",
		"d_lddturnaroundtimertest_ldd/winscw/udeb/d_lddturnaroundtimertest_UID_.o",
		"d_lddturnaroundtimertest_ldd/winscw/urel/d_lddturnaroundtimertest.o",
		"d_lddturnaroundtimertest_ldd/winscw/urel/d_lddturnaroundtimertest.UID.CPP",
		"d_lddturnaroundtimertest_ldd/winscw/urel/d_lddturnaroundtimertest_UID_.o",
		"t_sharedio3_exe/winscw/udeb/t_sharedio.o",
		"t_sharedio3_exe/winscw/udeb/t_sharedio3.UID.CPP",
		"t_sharedio3_exe/winscw/udeb/t_sharedio3_UID_.o",
		"t_sharedio3_exe/winscw/urel/t_sharedio.o",
		"t_sharedio3_exe/winscw/urel/t_sharedio3.UID.CPP",
		"t_sharedio3_exe/winscw/urel/t_sharedio3_UID_.o",
		"t_rbuf_exe/winscw/udeb/t_rbuf.o",
		"t_rbuf_exe/winscw/udeb/t_rbuf.UID.CPP",
		"t_rbuf_exe/winscw/udeb/t_rbuf_UID_.o",
		"t_rbuf_exe/winscw/urel/t_rbuf.o",
		"t_rbuf_exe/winscw/urel/t_rbuf.UID.CPP",
		"t_rbuf_exe/winscw/urel/t_rbuf_UID_.o"
		])
	t.mustmatch = []
	t.run()
	
	# Test keywords: version, firstlib, nocompresstarget
	t.id = "75e"
	t.name = "mmp_5"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp5/bld.inf -c armv5"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/fuzzv5.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/fuzzv5.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/fuzzlib.lib",
		"$(EPOCROOT)/epoc32/release/armv5/urel/fuzzlib.lib"
		]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp5/bld.inf", [
		"fuzzv5_exe/armv5/udeb/fuzzv5.o",
		"fuzzv5_exe/armv5/urel/fuzzv5.o",
		"fuzzlib_lib/armv5/udeb/uc_exe_.cpp",
		"fuzzlib_lib/armv5/urel/uc_exe_.cpp",
		"fuzzlib_lib/armv5/udeb/uc_exe_.o",
		"fuzzlib_lib/armv5/urel/uc_exe_.o",
		])
	t.run()

	t.id = "75f"
	t.name = "mmp_6"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp6_7/bld.inf -c armv5 -k -p diagsuppress.mmp -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/diagsuppress_test.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/diagsuppress_test.dll",
		]
	t.mustmatch = [
					"--diag_suppress 6780",
					"--diag_suppress 6331"
					]
	t.run()
	
	t.id = "75g"
	t.name = "mmp_7"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp6_7/bld.inf -c armv5 -k -p diagsuppress_noarmlibs.mmp -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/diagsuppress_noarmlibs_test.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/diagsuppress_noarmlibs_test.dll"
		]
	t.mustmatch = ["--diag_suppress 6331"]
	t.mustnotmatch = ["--diag_suppress 6780"]
	t.run()

	# Test keyword: version
	t.id = "75h"
	t.name = "mmp_8"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp8/bld.inf"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_mmp_version.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_mmp_version.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test_mmp_version.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/test_mmp_version.exe"
		]
	t.mustmatch = []
	t.mustnotmatch = []
	t.warnings = 2
	t.run()

	# Test keyword: armfpu softvfp|vfpv2
	# Both armv5 RVCT (9a+b) and GCCE (10) builds, as they differ in behaviour.
	t.id = "75i"
	t.name = "mmp_9a"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -p armfpu_soft.mmp -c armv5_urel -f-"			
	t.targets = []
	t.mustmatch = ["--fpu softvfp", "--fpu=softvfp"]
	t.mustnotmatch = ["--fpu vfpv2", "--fpu softvfp\+", "--fpu=vfpv2", "--fpu=softvfp\+"]
	t.warnings = 0
	t.run()
		
	t.id = "75j"
	t.name = "mmp_9b"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -c armv5_urel REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -p armfpu_vfpv2.mmp -c armv5_urel -f-"

	t.mustmatch = ["--fpu vfpv2", "--fpu=vfpv2"]
	t.mustnotmatch = ["--fpu softvfp", "--fpu=softvfp"]	
	t.run()
	
	t.id = "75ja"
	t.name = "mmp_9c"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -c armv5_urel REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -p \"armfpu_soft+vfpv2.mmp\" -c armv5_urel -f-"

	t.mustmatch = ["--fpu softvfp\+vfpv2", "--fpu=vfpv2"]
	t.mustnotmatch = ["--fpu vfpv2", "--fpu softvfp ", "--fpu=softvfp"]
	t.run()

	t.id = "75k"
	t.name = "mmp_10"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf  -c armv5_urel_gcce4_3_2 REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -c armv5_urel_gcce4_3_2 -f-"
	t.countmatch = [
		["-mfloat-abi=soft", 3],
		["--fpu=softvfp", 3] # gcce doesn't vary according to ARMFPU currently
	]
	t.mustmatch = []
	t.mustnotmatch = ["--fpu=vfpv2", "--fpu=softvfp\+"]
	t.run()
	
	# Test keywords: compresstarget, nocompresstarget, bytepaircompresstarget, inflatecompresstarget
	t.id = "75l"
	t.name = "mmp_11"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp11/bld.inf -c armv5_urel -f-"
	t.mustmatch_singleline = [
		"elf2e32.*--output.*\/compress\.exe.*--compressionmethod=inflate",
		"elf2e32.*--output.*\/nocompress\.exe.*--uncompressed",
		"elf2e32.*--output.*\/bytepaircompress\.exe.*--compressionmethod=bytepair",
		"elf2e32.*--output.*\/inflatecompress\.exe.*--compressionmethod=inflate",
		"elf2e32.*--output.*\/combinedcompress\.exe.*--compressionmethod=bytepair",		
		"COMPRESSTARGET keyword in .*combinedcompresstarget.mmp overrides earlier use of NOCOMPRESSTARGET",
		"INFLATECOMPRESSTARGET keyword in .*combinedcompresstarget.mmp overrides earlier use of COMPRESSTARGET",
		"BYTEPAIRCOMPRESSTARGET keyword in .*combinedcompresstarget.mmp overrides earlier use of INFLATECOMPRESSTARGET"
	]
	t.countmatch = []
	t.mustnotmatch = []
	t.warnings = 3
	t.run()

	# Test keyword: APPLY
	t.id = "75m"
	t.name = "apply"
	t.command = "sbs -b smoke_suite/test_resources/mmp/apply/bld.inf -f- -k --configpath=test/config"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_mmp_apply.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_mmp_apply.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test_mmp_apply.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/test_mmp_apply.exe"
		]
	t.mustmatch_singleline = ["-DAPPLYTESTEXPORTEDVAR",
	                          "-DAPPLYTESTAPPENDCDEFS"]
	t.countmatch = [["<error.*APPLY unknown variant 'no_such_var'", 2]]
	t.errors = 2 # no_such_var for armv5 and winscw
	t.warnings = 0
	t.returncode = 1
	t.run()

	# Test keyword: EPOCNESTEDEXCEPTIONS
	t.id = "75n"
	t.name = "epocnestedexceptions"
	t.command = "sbs -b smoke_suite/test_resources/mmp/epocnestedexceptions/bld.inf -c armv5_udeb -f-"

	# When EPOCNESTEDEXCEPTIONS is specified in the MMP file, a different static
	# run-time library should be used.
	t.mustmatch_singleline = ["usrt_nx_\d_\d\.lib"]
	t.mustnotmatch = ["usrt._.."]

	t.countmatch = []

	# The new static run-time libraries don't yet exist.
	t.errors = 1
	t.warnings = 1
	t.targets = []

	t.run()
	
	# Test keyword: DOCUMENT
	t.id = "75o"
	t.name = "mmp_keyword_document"
	# Note: in t.command, the makefile is cat'd through sed to remove the .DEFAULT double-colon rule's <warning> tag to ensure that t.run succeeds.
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp1/group/bld.inf -c armv5 reallyclean; " + \
				"sbs -b smoke_suite/test_resources/mmp/mmp1/group/bld.inf --no-depend-generate -c armv5_urel -m ${SBSMAKEFILE}; " + \
				"cat ${SBSMAKEFILE}_all.default"
	
	t.mustmatch_singleline = ["DOCUMENT:=.*test/smoke_suite/test_resources/mmp/mmp1/src/file01\.txt\\s+.*test/smoke_suite/test_resources/mmp/mmp1/src/file02\.txt"]
	t.mustnotmatch = []
	t.countmatch = []
	
	t.errors = 0
	t.warnings = 0
	t.returncode = 0
	t.targets = []
	
	t.run()
	
	t.id = "75"
	t.name = "mmp_keywords"
	t.print_result()
	return t
Пример #48
0
def run():
	result = SmokeTest.PASS
	
	t = SmokeTest()
	t.id = "0057a"
	t.name = "gccxml"
	t.usebash = True
	t.command = "sbs -b smoke_suite/test_resources/simple_gui/bld.inf " + \
			"-c gccxml_urel -m ${SBSMAKEFILE} -f ${SBSLOGFILE} && " + \
			"grep -o 'gcc.*-fpermissive' ${SBSLOGFILE}"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/gccxml/includeheaders.txt",
		"$(EPOCROOT)/epoc32/release/gccxml/urel/helloworldexe.gxp"
		]
	t.addbuildtargets('smoke_suite/test_resources/simple_gui/bld.inf', [
		"helloworld_exe/gccxml/HelloWorld.mmp.xml",
		"helloworld_exe/helloworld_HelloWorld.rsc.d",
		"helloworld_exe/gccxml/HelloWorld.rss.rfi",
		"helloworld_reg_exe/helloworld_reg_HelloWorld_reg.rsc.d",
		"helloworld_exe/gccxml/HelloWorld_reg.rss.rfi",
		"helloworld_exe/gccxml/urel/HelloWorld_Application.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_Application.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_AppUi.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_AppUi.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_AppView.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_AppView.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_Document.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_Document.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_Main.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_Main.xml"
	])
	t.mustmatch = [
		".*gcc.*-fpermissive.*"
	]
	# Windows-only until formal delivery of a Linux version of gccxml_cc1plus
	t.run("windows")
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL
	elif t.result == SmokeTest.SKIP:
		return t
	
	
	t = AntiTargetSmokeTest()
	t.id = "0057b"
	t.name = "gccxml_reallyclean"
	t.command = "sbs -b smoke_suite/test_resources/simple_gui/bld.inf " + \
			"-c gccxml_urel REALLYCLEAN"
	t.antitargets = ["$(EPOCROOT)/epoc32/release/gccxml/urel/helloworldexe.gxp"]
	t.addbuildantitargets('smoke_suite/test_resources/simple_gui/bld.inf', [
		"helloworld_exe/gccxml/HelloWorld.mmp.xml",
		"helloworld_exe/helloworld_HelloWorld.rsc.d",
		"helloworld_exe/gccxml/HelloWorld.rss.rfi",
		"helloworld_reg_exe/helloworld_reg_HelloWorld_reg.rsc.d",
		"helloworld_exe/gccxml/HelloWorld_reg.rss.rfi",
		"helloworld_exe/gccxml/urel/HelloWorld_Application.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_Application.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_AppUi.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_AppUi.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_AppView.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_AppView.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_Document.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_Document.xml",
		"helloworld_exe/gccxml/urel/HelloWorld_Main.xml.d",
		"helloworld_exe/gccxml/urel/HelloWorld_Main.xml"
	])
	t.run("windows")
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL
		
		
	t = SmokeTest()
	t.id = "0057c"
	t.name = "gccxml_var2"
	t.command = "sbs -b smoke_suite/test_resources/simple_gui/BldVar2.inf " + \
			"-c gccxml_urel -f -"
	
	# Don't allow -m or -f to be appended
	t.logfileOption = lambda :""
	t.makefileOption = lambda :""
	
	t.mustmatch = [".*__KERNEL_MODE__.*"]
	t.errors = 1 # not really VAR2 code, so it wont build cleanly
	t.returncode = 1
	t.run("windows")
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL
		
		
	t = SmokeTest()
	t.id = "0057d"
	t.name = "gccxml_stdcpp"
	t.command = "sbs -b smoke_suite/test_resources/simple_gui/Bld_stdcpp.inf " + \
			"-c gccxml_urel -f -"
	
	# Don't allow -m or -f to be appended
	t.logfileOption = lambda :""
	t.makefileOption = lambda :""
	
	t.mustmatch = [".*__SYMBIAN_STDCPP_SUPPORT__.*"]
	t.errors = 0 # reset after previous run
	t.run("windows")
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL
	
		
	t.id = "57"
	t.name = "gccxml"
	t.result = result
	t.print_result()
	return t
def run():
    result = SmokeTest.PASS

    t = SmokeTest()
    t.name = "exe_armv5_winscw_single_file_baseline_build"

    # Build component
    t.command = "sbs -b smoke_suite/test_resources/simple_gui/Bld.inf -c armv5 -c winscw"
    t.addbuildtargets('smoke_suite/test_resources/simple_gui/Bld.inf', [
        "helloworld_exe/helloworld.mbm_bmconvcommands",
        "HelloWorld_exe/HelloWorld_HelloWorld.rsc",
        "HelloWorld_exe/HelloWorld_HelloWorld.rsc.rpp",
        "HelloWorld_exe/HelloWorld_HelloWorld.rsc.d",
        "helloworld_exe/armv5/udeb/HelloWorld_Application.o",
        "helloworld_exe/armv5/udeb/HelloWorld_Application.o.d",
        "helloworld_exe/armv5/udeb/HelloWorld_AppUi.o",
        "helloworld_exe/armv5/udeb/HelloWorld_AppUi.o.d",
        "helloworld_exe/armv5/udeb/HelloWorld_AppView.o",
        "helloworld_exe/armv5/udeb/HelloWorld_AppView.o.d",
        "helloworld_exe/armv5/udeb/HelloWorld_Document.o",
        "helloworld_exe/armv5/udeb/HelloWorld_Document.o.d",
        "helloworld_exe/armv5/udeb/HelloWorld_Main.o",
        "helloworld_exe/armv5/udeb/HelloWorld_Main.o.d",
        "helloworld_exe/armv5/udeb/helloworld_udeb_objects.via",
        "helloworld_exe/armv5/urel/HelloWorld_Application.o",
        "helloworld_exe/armv5/urel/HelloWorld_Application.o.d",
        "helloworld_exe/armv5/urel/HelloWorld_AppUi.o",
        "helloworld_exe/armv5/urel/HelloWorld_AppUi.o.d",
        "helloworld_exe/armv5/urel/HelloWorld_AppView.o",
        "helloworld_exe/armv5/urel/HelloWorld_AppView.o.d",
        "helloworld_exe/armv5/urel/HelloWorld_Document.o",
        "helloworld_exe/armv5/urel/HelloWorld_Document.o.d",
        "helloworld_exe/armv5/urel/HelloWorld_Main.o",
        "helloworld_exe/armv5/urel/HelloWorld_Main.o.d",
        "helloworld_exe/armv5/urel/helloworld_urel_objects.via",
        "helloworld_exe/winscw/udeb/helloworld.UID.CPP",
        "helloworld_exe/winscw/udeb/HelloWorld_Application.dep",
        "helloworld_exe/winscw/udeb/HelloWorld_Application.o",
        "helloworld_exe/winscw/udeb/HelloWorld_Application.o.d",
        "helloworld_exe/winscw/udeb/HelloWorld_AppUi.dep",
        "helloworld_exe/winscw/udeb/HelloWorld_AppUi.o",
        "helloworld_exe/winscw/udeb/HelloWorld_AppUi.o.d",
        "helloworld_exe/winscw/udeb/HelloWorld_AppView.dep",
        "helloworld_exe/winscw/udeb/HelloWorld_AppView.o",
        "helloworld_exe/winscw/udeb/HelloWorld_AppView.o.d",
        "helloworld_exe/winscw/udeb/HelloWorld_Document.dep",
        "helloworld_exe/winscw/udeb/HelloWorld_Document.o",
        "helloworld_exe/winscw/udeb/HelloWorld_Document.o.d",
        "helloworld_exe/winscw/udeb/HelloWorld_Main.dep",
        "helloworld_exe/winscw/udeb/HelloWorld_Main.o",
        "helloworld_exe/winscw/udeb/HelloWorld_Main.o.d",
        "helloworld_exe/winscw/udeb/helloworld_udeb_objects.lrf",
        "helloworld_exe/winscw/udeb/helloworld_UID_.dep",
        "helloworld_exe/winscw/udeb/helloworld_UID_.o",
        "helloworld_exe/winscw/udeb/helloworld_UID_.o.d",
        "helloworld_exe/winscw/urel/helloworld.UID.CPP",
        "helloworld_exe/winscw/urel/HelloWorld_Application.dep",
        "helloworld_exe/winscw/urel/HelloWorld_Application.o",
        "helloworld_exe/winscw/urel/HelloWorld_Application.o.d",
        "helloworld_exe/winscw/urel/HelloWorld_AppUi.dep",
        "helloworld_exe/winscw/urel/HelloWorld_AppUi.o",
        "helloworld_exe/winscw/urel/HelloWorld_AppUi.o.d",
        "helloworld_exe/winscw/urel/HelloWorld_AppView.dep",
        "helloworld_exe/winscw/urel/HelloWorld_AppView.o",
        "helloworld_exe/winscw/urel/HelloWorld_AppView.o.d",
        "helloworld_exe/winscw/urel/HelloWorld_Document.dep",
        "helloworld_exe/winscw/urel/HelloWorld_Document.o",
        "helloworld_exe/winscw/urel/HelloWorld_Document.o.d",
        "helloworld_exe/winscw/urel/HelloWorld_Main.dep",
        "helloworld_exe/winscw/urel/HelloWorld_Main.o",
        "helloworld_exe/winscw/urel/HelloWorld_Main.o.d",
        "helloworld_exe/winscw/urel/helloworld_UID_.dep",
        "helloworld_exe/winscw/urel/helloworld_UID_.o",
        "helloworld_exe/winscw/urel/helloworld_UID_.o.d",
        "helloworld_exe/winscw/urel/helloworld_urel_objects.lrf",
        "HelloWorld_reg_exe/HelloWorld_reg_HelloWorld_reg.rsc",
        "HelloWorld_reg_exe/HelloWorld_reg_HelloWorld_reg.rsc.rpp",
        "HelloWorld_reg_exe/HelloWorld_reg_HelloWorld_reg.rsc.d"
    ])
    t.run()

    # Ensure we don't clean up from the previous build in any subsequent runs
    t.addbuildtargets('smoke_suite/test_resources/simple_gui/Bld.inf', [])
    t.targets = []
    t.usebash = True

    # Touch both a straight source and a resource file and confirm we can recompile in isolation without additional impact
    t.name = "exe_armv5_winscw_single_file_touch_rebuild"
    t.command = """
		sleep 1
		touch smoke_suite/test_resources/simple_gui/HelloWorld_Document.cpp
		touch smoke_suite/test_resources/simple_gui/HelloWorld.rss
		sbs -f - --source-target=smoke_suite/test_resources/simple_gui/HelloWorld_Document.cpp --source-target=smoke_suite/test_resources/simple_gui/HelloWorld.rss -b smoke_suite/test_resources/simple_gui/Bld.inf"""
    t.countmatch = [[".*recipe name='resource(dependencies|compile)'", 2],
                    [".*recipe name='compile'.*", 2],
                    [".*recipe name='win32compile2object'.*", 2]]
    t.mustnotmatch = [".*recipe name='(win32simplelink|postlink|link)'.*"]
    t.run()

    # Attempt separate source and resource file compile where nothing should be done
    t.name = "exe_armv5_winscw_single_file_notouch_rebuild"
    t.command = "sbs -f - --source-target=smoke_suite/test_resources/simple_gui/HelloWorld_Document.cpp --source-target=smoke_suite/test_resources/simple_gui/HelloWorld.rss -b smoke_suite/test_resources/simple_gui/Bld.inf"
    t.mustmatch = []
    t.countmatch = [[".*make.*Nothing to be done for.*SOURCETARGET_.*", 10]]
    t.mustnotmatch = [
        ".*recipe name='(resourcecompile|win32compile2object|compile|win32simplelink|postlink|link)'.*"
    ]
    t.run()

    t.name = "exe_armv5_winscw_single_file"
    t.description = """Builds a component and tests single file compilation for straight source and resource files"""
    t.print_result()
    return t
Пример #50
0
def run():
    t = SmokeTest()
    t.name = "openenvironment"
    t.description = """Test STDEXE, STDLIB and STDDLL creation; Test open environment project linking against a symbian environment
		library; Test symbian environment project linking against an open environment library"""
    t.usebash = True
    t.command = "sbs -k -b smoke_suite/test_resources/oe/group/bld.inf -c armv5 -c winscw " + \
     "-m ${SBSMAKEFILE} -f ${SBSLOGFILE}; grep -E \"(armlink|checklib|mwldsym2)\" ${SBSLOGFILE}"
    t.errors = 1  # The test has errors so make will return a fail code and raptor will report this
    t.targets = [
        "$(EPOCROOT)/epoc32/release/armv5/urel/t_oedll.dll.sym",
        "$(EPOCROOT)/epoc32/release/armv5/urel/symbian_test.lib",
        "$(EPOCROOT)/epoc32/release/armv5/urel/t_oeexe.exe.map",
        "$(EPOCROOT)/epoc32/release/armv5/urel/t_oelib.lib",
        "$(EPOCROOT)/epoc32/release/armv5/urel/t_oeexe.exe",
        "$(EPOCROOT)/epoc32/release/armv5/urel/t_oeexe.exe.sym",
        "$(EPOCROOT)/epoc32/release/armv5/urel/t_oedll.dll.map",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/t_oedll.dll.sym",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/symbian_test.lib",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/t_oeexe.exe.map",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/t_oelib.lib",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/t_oeexe.exe",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/t_oeexe.exe.sym",
        "$(EPOCROOT)/epoc32/release/armv5/udeb/t_oedll.dll.map",
        "$(EPOCROOT)/epoc32/release/armv5/lib/t_oedll.dso",
        "$(EPOCROOT)/epoc32/release/armv5/lib/t_oedll{000a0000}.dso",
        "$(EPOCROOT)/epoc32/release/winscw/urel/symbian_test.lib",
        "$(EPOCROOT)/epoc32/release/winscw/urel/t_oedll.dll",
        "$(EPOCROOT)/epoc32/release/winscw/urel/t_oeexe.exe.map",
        "$(EPOCROOT)/epoc32/release/winscw/urel/t_oelib.lib",
        "$(EPOCROOT)/epoc32/release/winscw/urel/t_oeexe.exe",
        "$(EPOCROOT)/epoc32/release/winscw/urel/t_oedll.dll.map",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/symbian_test.lib",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/t_oedll.lib",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/t_oedll.dll",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/t_oelib.lib"
    ]
    t.addbuildtargets(
        'smoke_suite/test_resources/oe/group/bld.inf',
        [
            "t_oedll_dll/armv5/urel/t_oedll{000a0000}.dso",
            "t_oedll_dll/armv5/urel/t_oedll_urel_objects.via",
            "t_oedll_dll/armv5/urel/t_oedll.o",
            "t_oedll_dll/armv5/urel/t_oedll.o.d",
            # either prep file can exist - luck determines which
            [
                't_oedll_dll/armv5/urel/t_oedll.prep',
                't_oedll_dll/armv5/udeb/t_oedll.prep'
            ],
            "t_oedll_dll/armv5/urel/t_oedll{000a0000}.def",
            "t_oedll_dll/armv5/udeb/t_oedll{000a0000}.dso",
            "t_oedll_dll/armv5/udeb/t_oedll_udeb_objects.via",
            "t_oedll_dll/armv5/udeb/t_oedll.o",
            "t_oedll_dll/armv5/udeb/t_oedll.o.d",
            "t_oedll_dll/armv5/udeb/t_oedll{000a0000}.def",
            "symbian_test_lib/armv5/urel/symbian_test_urel_objects.via",
            "symbian_test_lib/armv5/urel/symbian_lib.o.d",
            "symbian_test_lib/armv5/urel/symbian_lib.o",
            "symbian_test_lib/armv5/udeb/symbian_test_udeb_objects.via",
            "symbian_test_lib/armv5/udeb/symbian_lib.o.d",
            "symbian_test_lib/armv5/udeb/symbian_lib.o",
            "wrong_newlib_test_oeexe_exe/armv5/urel/wrong_newlib_test_oeexe_urel_objects.via",
            "wrong_newlib_test_oeexe_exe/armv5/urel/t_oeexe.o",
            "wrong_newlib_test_oeexe_exe/armv5/urel/t_oeexe.o.d",
            "wrong_newlib_test_oeexe_exe/armv5/udeb/t_oeexe.o",
            "wrong_newlib_test_oeexe_exe/armv5/udeb/wrong_newlib_test_oeexe_udeb_objects.via",
            "wrong_newlib_test_oeexe_exe/armv5/udeb/t_oeexe.o.d",
            "wrong_newlib_seexe_exe/armv5/urel/wrong_newlib_seexe_urel_objects.via",
            "wrong_newlib_seexe_exe/armv5/urel/wrong_newlib_symbian.o",
            "wrong_newlib_seexe_exe/armv5/urel/wrong_newlib_symbian.o.d",
            "wrong_newlib_seexe_exe/armv5/udeb/wrong_newlib_seexe_udeb_objects.via",
            "wrong_newlib_seexe_exe/armv5/udeb/wrong_newlib_symbian.o",
            "wrong_newlib_seexe_exe/armv5/udeb/wrong_newlib_symbian.o.d",
            "t_oeexe_exe/armv5/urel/t_oeexe_urel_objects.via",
            "t_oeexe_exe/armv5/urel/t_oeexe.o",
            "t_oeexe_exe/armv5/urel/t_oeexe.o.d",
            "t_oeexe_exe/armv5/udeb/t_oeexe.o",
            "t_oeexe_exe/armv5/udeb/t_oeexe.o.d",
            "t_oeexe_exe/armv5/udeb/t_oeexe_udeb_objects.via",
            "t_oelib_lib/armv5/urel/t_oelib_urel_objects.via",
            "t_oelib_lib/armv5/urel/t_oelib.o",
            "t_oelib_lib/armv5/urel/t_oelib.o.d",
            "t_oelib_lib/armv5/udeb/t_oelib.o",
            "t_oelib_lib/armv5/udeb/t_oelib_udeb_objects.via",
            "t_oelib_lib/armv5/udeb/t_oelib.o.d",
            "t_oedll_dll/winscw/urel/t_oedll.dep",
            "t_oedll_dll/winscw/urel/t_oedll.lib",
            "t_oedll_dll/winscw/urel/t_oedll_SYM_.cpp",
            "t_oedll_dll/winscw/urel/t_oedll.dll",
            "t_oedll_dll/winscw/urel/t_oedll_UID_.o",
            "t_oedll_dll/winscw/urel/t_oedll_SYM_.o",
            "t_oedll_dll/winscw/urel/t_oedll.o",
            "t_oedll_dll/winscw/urel/t_oedll_UID_.o.d",
            "t_oedll_dll/winscw/urel/t_oedll.o.d",
            "t_oedll_dll/winscw/urel/t_oedll_UID_.dep",
            "t_oedll_dll/winscw/urel/t_oedll.sym",
            "t_oedll_dll/winscw/urel/t_oedll.UID.CPP",
            "t_oedll_dll/winscw/urel/t_oedll_SYM_.o.d",
            "t_oedll_dll/winscw/urel/t_oedll_SYM_.dep",
            # The prep.def file can be in urel or udeb
            [
                't_oedll_dll/winscw/urel/t_oedll.prep.def',
                't_oedll_dll/winscw/udeb/t_oedll.prep.def'
            ],
            "t_oedll_dll/winscw/urel/t_oedll.def",
            "t_oedll_dll/winscw/urel/t_oedll.inf",
            "t_oedll_dll/winscw/udeb/t_oedll.dep",
            "t_oedll_dll/winscw/udeb/t_oedll.lib",
            "t_oedll_dll/winscw/udeb/t_oedll_SYM_.cpp",
            "t_oedll_dll/winscw/udeb/t_oedll.dll",
            "t_oedll_dll/winscw/udeb/t_oedll_UID_.o",
            "t_oedll_dll/winscw/udeb/t_oedll_SYM_.o",
            "t_oedll_dll/winscw/udeb/t_oedll.o",
            "t_oedll_dll/winscw/udeb/t_oedll_UID_.o.d",
            "t_oedll_dll/winscw/udeb/t_oedll.o.d",
            "t_oedll_dll/winscw/udeb/t_oedll_UID_.dep",
            "t_oedll_dll/winscw/udeb/t_oedll.sym",
            "t_oedll_dll/winscw/udeb/t_oedll.UID.CPP",
            "t_oedll_dll/winscw/udeb/t_oedll_SYM_.o.d",
            "t_oedll_dll/winscw/udeb/t_oedll_SYM_.dep",
            "t_oedll_dll/winscw/udeb/t_oedll.def",
            "t_oedll_dll/winscw/udeb/t_oedll.inf",
            "symbian_test_lib/winscw/urel/symbian_lib.dep",
            "symbian_test_lib/winscw/urel/symbian_lib.o.d",
            "symbian_test_lib/winscw/urel/symbian_lib.o",
            "symbian_test_lib/winscw/udeb/symbian_lib.dep",
            "symbian_test_lib/winscw/udeb/symbian_lib.o.d",
            "symbian_test_lib/winscw/udeb/symbian_lib.o",
            "wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe_UID_.dep",
            "wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe_UID_.o.d",
            "wrong_newlib_test_oeexe_exe/winscw/urel/t_oeexe_wins.dep",
            "wrong_newlib_test_oeexe_exe/winscw/urel/t_oeexe_wins.o",
            "wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe.UID.CPP",
            "wrong_newlib_test_oeexe_exe/winscw/urel/wrong_newlib_test_oeexe_UID_.o",
            "wrong_newlib_test_oeexe_exe/winscw/urel/t_oeexe_wins.o.d",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe_UID_.dep",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe_UID_.o.d",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/t_oeexe_wins.dep",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/t_oeexe_wins.o",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe.UID.CPP",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/wrong_newlib_test_oeexe_UID_.o",
            "wrong_newlib_test_oeexe_exe/winscw/udeb/t_oeexe_wins.o.d",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe_UID_.dep",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe_UID_.o",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_symbian.dep",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_symbian.o",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_symbian.o.d",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe.UID.CPP",
            "wrong_newlib_seexe_exe/winscw/urel/wrong_newlib_seexe_UID_.o.d",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe_UID_.dep",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe_UID_.o",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_symbian.dep",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_symbian.o",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_symbian.o.d",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe.UID.CPP",
            "wrong_newlib_seexe_exe/winscw/udeb/wrong_newlib_seexe_UID_.o.d",
            "t_oeexe_exe/winscw/urel/t_oeexe_UID_.o",
            "t_oeexe_exe/winscw/urel/t_oeexe_UID_.dep",
            "t_oeexe_exe/winscw/urel/t_oeexe_wins.dep",
            "t_oeexe_exe/winscw/urel/t_oeexe_wins.o",
            "t_oeexe_exe/winscw/urel/t_oeexe_UID_.o.d",
            "t_oeexe_exe/winscw/urel/t_oeexe.UID.CPP",
            "t_oeexe_exe/winscw/urel/t_oeexe_wins.o.d",
            "t_oeexe_exe/winscw/udeb/t_oeexe_UID_.o",
            "t_oeexe_exe/winscw/udeb/t_oeexe_UID_.dep",
            "t_oeexe_exe/winscw/udeb/t_oeexe_wins.dep",
            "t_oeexe_exe/winscw/udeb/t_oeexe_wins.o",
            "t_oeexe_exe/winscw/udeb/t_oeexe_UID_.o.d",
            "t_oeexe_exe/winscw/udeb/t_oeexe.UID.CPP",
            "t_oeexe_exe/winscw/udeb/t_oeexe_wins.o.d",
            "t_oelib_lib/winscw/urel/t_oelib.o",
            "t_oelib_lib/winscw/urel/t_oelib.o.d",
            "t_oelib_lib/winscw/urel/t_oelib.dep",
            "t_oelib_lib/winscw/udeb/t_oelib.o",
            "t_oelib_lib/winscw/udeb/t_oelib.o.d",
            "t_oelib_lib/winscw/udeb/t_oelib.dep"
        ])

    # On 9.4 the open environment checks for
    # mixed symbianc++ and stdc++ new/delete won't fail
    if getsymbianversion() != "9.4":
        t.mustmatch = [
            '.*checklib: error: library .*epoc32.release.armv5.urel.symbian_test.lib is incompatible with standard.*',
            '.*checklib: error: library .*epoc32.release.armv5.urel.t_oelib.lib is incompatible with Symbian.*',
            '.*checklib: error: library .*epoc32.release.armv5.udeb.symbian_test.lib is incompatible with standard.*',
            '.*checklib: error: library .*epoc32.release.armv5.udeb.t_oelib.lib is incompatible with Symbian.*',
            '.*checklib: error: library .*epoc32.release.winscw.urel.symbian_test.lib is incompatible with standard.*',
            '.*checklib: error: library .*epoc32.release.winscw.urel.t_oelib.lib is incompatible with Symbian.*',
            '.*checklib: error: library .*epoc32.release.winscw.udeb.t_oelib.lib is incompatible with Symbian.*',
            '.*checklib: error: library .*epoc32.release.winscw.udeb.symbian_test.lib is incompatible with standard.*',
            '.*armlink.*oe_exe_without_stdcpp.*scppnwdl.dso.*',
            '.*armlink.*symbian_exe_with_stdcpp.*stdnew.dso.*',
            '.*armlink.*oedll.*stdnew.dso.*', '.*armlink.*oeexe.*stdnew.dso.*',
            '.*armlink.*symbian_newlib.exe.*scppnwdl.dso.*'
        ]
        t.mustnotmatch = [
            '.*armlink.*oe_exe_without_stdcpp.*stdnew.dso.*',
            '.*armlink.*symbian_exe_with_stdcpp.*scppnwdl.dso.*',
            '.*armlink.*oedll.*scppnwdl.dso.*',
            '.*armlink.*oeexe.*scppnwdl.dso.*',
            '.*armlink.*symbian_newlib.exe.*stdnew.dso.*',
            '.*mwldsym2.*scppnwdl.lib.*symbian_exe_with_stdcpp.exe.*'
        ]
    else:
        # these files will build for 9.4
        t.targets.extend([
            "$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_oeexe.exe",
            "$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_oeexe.exe.map",
            "$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_oeexe.exe",
            "$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_oeexe.exe.map",
            "$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_seexe.exe",
            "$(EPOCROOT)/epoc32/release/winscw/urel/wrong_newlib_test_seexe.exe.map",
            "$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_seexe.exe",
            "$(EPOCROOT)/epoc32/release/winscw/udeb/wrong_newlib_test_seexe.exe.map",
            "$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_oeexe.exe",
            "$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_oeexe.exe",
            "$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_seexe.exe",
            "$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_seexe.exe",
            "$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_oeexe.exe.map",
            "$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_oeexe.exe.map",
            "$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_seexe.exe.map",
            "$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_seexe.exe.map",
            "$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_oeexe.exe.sym",
            "$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_oeexe.exe.sym",
            "$(EPOCROOT)/epoc32/release/armv5/urel/wrong_newlib_test_seexe.exe.sym",
            "$(EPOCROOT)/epoc32/release/armv5/udeb/wrong_newlib_test_seexe.exe.sym"
        ])
    t.run()
    return t
Пример #51
0
def run():
	t = SmokeTest()
	t.name = "dll_armv5_winscw_freeze"
	t.description = """Builds a component with unfrozen exports from clean,
		followed by a FREEZE, a further CLEAN and then a check that new .def
		files are present. The PERL environment variable is set to the absolute
		Perl path in order to test a known issue with the execution of tools
		such as efreeze under Cygwin when multiple arguments are listed.
		Part b tests whether removing an export works when using the variant;
		remove_freeze"""
	t.usebash = True
	
	perl_location = where("perl")
	
	t.command = """
sbs -b smoke_suite/test_resources/unfrozen/freeze.inf -p unfrozensymbols_for_freeze.mmp -c armv5 -c winscw CLEAN > /dev/null &&
export PERL="{0}" &&
sbs -b smoke_suite/test_resources/unfrozen/freeze.inf -p unfrozensymbols_for_freeze.mmp -c armv5 -c winscw > /dev/null &&
sbs -b smoke_suite/test_resources/unfrozen/freeze.inf -p unfrozensymbols_for_freeze.mmp -c armv5_urel -c winscw_urel FREEZE -m ${{SBSMAKEFILE}} -f ${{SBSLOGFILE}}
""".format(perl_location)

	t.targets = [
		"smoke_suite/test_resources/unfrozen/frozen/bwins/frozenu.def",
		"smoke_suite/test_resources/unfrozen/frozen/eabi/frozenu.def"		
		]

	t.warnings = 2	
	t.run()
	
	
	t.name = "armv5_re-freeze_with_removed_export"
	
	t.command = "sbs -b smoke_suite/test_resources/unfrozen/freeze.inf" \
			" -p frozen_with_removed_export.mmp -c armv5_urel ;" \
			" sbs -b smoke_suite/test_resources/unfrozen/freeze.inf" \
			" -p frozen_with_removed_export.mmp FREEZE" \
			" -c armv5_urel.remove_freeze" \
			" -m ${SBSMAKEFILE} -f ${SBSLOGFILE} &&" \
			" grep -ir '_ZN10CMessenger11ShowMessageEv @ 1 NONAME ABSENT' $(SBS_HOME)/test/smoke_suite/test_resources/unfrozen/frozen/eabi/frozenu.def"
			
	t.targets = []
	t.mustmatch = [
		"_ZN10CMessenger11ShowMessageEv @ 1 NONAME ABSENT"
	]
	t.warnings = 0
	t.errors = 1
			
	t.run()
	
	
	t.name = "winscw_re-freeze_with_removed_export"
	
	t.command = "sbs -b smoke_suite/test_resources/unfrozen/freeze.inf" \
			" -p frozen_with_removed_export.mmp -c winscw_urel ;" \
			" sbs -b smoke_suite/test_resources/unfrozen/freeze.inf" \
			" -p frozen_with_removed_export.mmp FREEZE" \
			" -c winscw_urel.remove_freeze" \
			" -m ${SBSMAKEFILE} -f ${SBSLOGFILE} &&" \
			" grep -ir '?ShowMessage@CMessenger@@QAEXXZ @ 3 NONAME ABSENT' $(SBS_HOME)/test/smoke_suite/test_resources/unfrozen/frozen/bwins/frozenu.def"

	t.mustmatch = [
		"\?ShowMessage@CMessenger@@QAEXXZ @ 3 NONAME ABSENT"
	]
			
	t.run()
	

	t.name = "efreeze_info"
	
	t.command = "sbs -b smoke_suite/test_resources/unfrozen/freeze.inf" \
			+ " -p unfrozensymbols_for_freeze.mmp -c winscw freeze"
			
	t.mustmatch = [
		"EFREEZE: DEF file up to date"
	]
	t.warnings = 0
	t.errors = 0
			
	t.run()


	t.name = "dll_armv5_winscw_freeze"
	t.print_result()
	return t
def run():
	t = SmokeTest()	
	t.description = "Tests Raptor can build win32 tools on linux"

	t.id = "111a"
	t.name = "tools2_cross_compilation_pdrtran" 
	t.command = "sbs -b smoke_suite/test_resources/tools2/cross/BLD.INF -p PDRTRAN.MMP -c tools2 -c tools2.win32"

	t.targets = [
			"$(EPOCROOT)/epoc32/release/tools2/deb/pdrtran.exe",
			"$(EPOCROOT)/epoc32/release/tools2/rel/pdrtran.exe",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/deb/pdrtran",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/rel/pdrtran",
			"$(EPOCROOT)/epoc32/tools/pdrtran.exe",
			"$(EPOCROOT)/epoc32/tools/pdrtran"
			]
	t.addbuildtargets("smoke_suite/test_resources/tools2/cross/BLD.INF", [
			"pdrtran_/pdrtran_exe/tools2/deb/PDRTRAN.o",
			"pdrtran_/pdrtran_exe/tools2/deb/LEXICAL.o",
			"pdrtran_/pdrtran_exe/tools2/deb/PDRREADR.o",
			"pdrtran_/pdrtran_exe/tools2/deb/PDRRECRD.o",
			"pdrtran_/pdrtran_exe/tools2/deb/READER.o",
			"pdrtran_/pdrtran_exe/tools2/deb/RECORD.o",
			"pdrtran_/pdrtran_exe/tools2/deb/STRNG.o",
			"pdrtran_/pdrtran_exe/tools2/rel/PDRTRAN.o",
			"pdrtran_/pdrtran_exe/tools2/rel/LEXICAL.o",
			"pdrtran_/pdrtran_exe/tools2/rel/PDRREADR.o",
			"pdrtran_/pdrtran_exe/tools2/rel/PDRRECRD.o",
			"pdrtran_/pdrtran_exe/tools2/rel/READER.o",
			"pdrtran_/pdrtran_exe/tools2/rel/RECORD.o",
			"pdrtran_/pdrtran_exe/tools2/rel/STRNG.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/PDRTRAN.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/LEXICAL.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/PDRREADR.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/PDRRECRD.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/READER.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/RECORD.o",
			"pdrtran_/pdrtran_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/STRNG.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/PDRTRAN.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/LEXICAL.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/PDRREADR.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/PDRRECRD.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/READER.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/RECORD.o",
			"pdrtran_/pdrtran_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/STRNG.o"
			])
	t.run("linux")

	
	t.id = "111b"
	t.name = "tools2_cross_compilation_libs"
	t.command = "sbs -b smoke_suite/test_resources/tools2/bld.inf -c tools2.win32 -c tools2"

	t.targets = [
			"$(EPOCROOT)/epoc32/release/tools2/deb/tool_exe.exe",
			"$(EPOCROOT)/epoc32/release/tools2/deb/libtool_lib1.a",
			"$(EPOCROOT)/epoc32/release/tools2/deb/libtool_lib2.a",
			"$(EPOCROOT)/epoc32/release/tools2/rel/tool_exe.exe",
			"$(EPOCROOT)/epoc32/release/tools2/rel/libtool_lib1.a",
			"$(EPOCROOT)/epoc32/release/tools2/rel/libtool_lib2.a",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/deb/tool_exe",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/deb/libtool_lib1.a",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/deb/libtool_lib2.a",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/rel/tool_exe",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/rel/libtool_lib1.a",
			"$(EPOCROOT)/epoc32/release/tools2/$(HOSTPLATFORM32_DIR)/rel/libtool_lib2.a",
			"$(EPOCROOT)/epoc32/tools/tool_exe.exe",
			"$(EPOCROOT)/epoc32/tools/tool_exe"
			]
	t.addbuildtargets("smoke_suite/test_resources/tools2/bld.inf", [
			"libtool_lib1_a/libtool_lib1_lib/tools2/rel/tool_lib1_b.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/rel/tool_lib1_a.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/rel/tool_lib2_b.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/rel/tool_lib2_a.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/deb/tool_lib1_b.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/deb/tool_lib1_a.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/deb/tool_lib2_a.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/deb/tool_lib2_b.o",
			"tool_exe_exe/tool_exe_exe/tools2/rel/tool_exe_a.o",
			"tool_exe_exe/tool_exe_exe/tools2/rel/tool_exe_b.o",
			"tool_exe_exe/tool_exe_exe/tools2/deb/tool_exe_b.o",
			"tool_exe_exe/tool_exe_exe/tools2/deb/tool_exe_a.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/rel/$(HOSTPLATFORM32_DIR)/tool_lib1_b.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/rel/$(HOSTPLATFORM32_DIR)/tool_lib1_a.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/rel/$(HOSTPLATFORM32_DIR)/tool_lib2_b.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/rel/$(HOSTPLATFORM32_DIR)/tool_lib2_a.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/deb/$(HOSTPLATFORM32_DIR)/tool_lib1_b.o",
			"libtool_lib1_a/libtool_lib1_lib/tools2/deb/$(HOSTPLATFORM32_DIR)/tool_lib1_a.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/deb/$(HOSTPLATFORM32_DIR)/tool_lib2_a.o",
			"libtool_lib2_a/libtool_lib2_lib/tools2/deb/$(HOSTPLATFORM32_DIR)/tool_lib2_b.o",
			"tool_exe_exe/tool_exe_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/tool_exe_a.o",
			"tool_exe_exe/tool_exe_exe/tools2/rel/$(HOSTPLATFORM32_DIR)/tool_exe_b.o",
			"tool_exe_exe/tool_exe_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/tool_exe_b.o",
			"tool_exe_exe/tool_exe_exe/tools2/deb/$(HOSTPLATFORM32_DIR)/tool_exe_a.o"
			])
	t.run("linux")


	t.usebash = True
	t.id = "111c"
	t.name = "tools2_cross_compilation_toolcheck_linux"
	t.command = "$(EPOCROOT)/epoc32/tools/pdrtran smoke_suite/test_resources/tools2/cross/TEST.PD $(EPOCROOT)/epoc32/build/TEST_PDRTRAN.PDR"
	t.targets = [
		 	"$(EPOCROOT)/epoc32/build/TEST_PDRTRAN.PDR"
			]
	t.mustmatch = [
			"PDRTRAN V41"
			]		
	t.run("linux")

	
	t.id = "111d"
	t.name = "tools2_cross_compilation_toolcheck_windows"
	t.command = "file $(EPOCROOT)/epoc32/tools/pdrtran.exe"
	t.targets = []
	t.mustmatch = [
			"MS Windows"
			]		
	t.run("linux")


	t.id = "111e"
	t.name = "tools2_cross_compilation_platmacro_linux"
	t.command = "sbs -b smoke_suite/test_resources/tools2/cross/BLD.INF -p platmacros.mmp -c tools2"
	t.targets = [
			"$(EPOCROOT)/epoc32/tools/test_platmacros"
			]
	t.mustmatch = [
			"TOOLS2_LINUX"
			]
	t.mustnotmatch = [
			"TOOLS2_WINDOWS"
			]
	t.warnings = 1
	t.run("linux")


	t.id = "111f"
	t.name = "tools2_cross_compilation_platmacro_windows"
	t.command = "sbs -b smoke_suite/test_resources/tools2/cross/BLD.INF -p platmacros.mmp -c tools2.win32"
	t.targets = [
			"$(EPOCROOT)/epoc32/tools/test_platmacros.exe"
			]
	t.mustmatch = [
			"TOOLS2_WINDOWS"
			]
	t.mustnotmatch = [
			"TOOLS2_LINUX"
			]
	t.warnings = 1
	t.run("linux")


	t.id = "111"
	t.name = "tools2_cross_compilation"
	t.print_result()
	return t
Пример #53
0
def run():
	t = SmokeTest()
	t.description = "This testcase tests all mmp keywords including new implementation of 'paged/unpaged code/data'"
	t.usebash = True
	
	t.name = "mmp_paging_keywords"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp1/group/bld.inf -c armv5 -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/shutdownsrv.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/shutdownsrv.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/shutdownsrv.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/shutdownsrv.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/lib/exportlibrary_shutdownsrv.dso",
		"$(EPOCROOT)/epoc32/release/armv5/lib/exportlibrary_shutdownsrv{000a0000}.dso",
	]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp1/group/bld.inf", [
		"shutdownsrv_dll/armv5/udeb/shutdownsrv.o",
		"shutdownsrv_dll/armv5/urel/shutdownsrv.o",
		"shutdownsrv_dll/armv5/udeb/shutdownsrvpatchdata.o",
		"shutdownsrv_dll/armv5/urel/shutdownsrvpatchdata.o",
		"shutdownsrv_dll/armv5/udeb/shutdowntimer.o",
		"shutdownsrv_dll/armv5/urel/shutdowntimer.o"
		])
	t.mustmatch = [
		".*elf2e32.*(--defaultpaged|--codepaging=default.*--datapaging=default).*",
		".*armlink.*--verbose.*"
	]
	t.run()

	t.name = "mmp_option_armcc_and_armasm"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp2/group/bld.inf -c armv5 -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/imageprocessorperf.lib",
		"$(EPOCROOT)/epoc32/release/armv5/urel/imageprocessorperf.lib"		
	]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp2/group/bld.inf", [
		"imageprocessorperf_lib/armv5/udeb/ColorConverter.o",
		"imageprocessorperf_lib/armv5/urel/ColorConverter.o",
		"imageprocessorperf_lib/armv5/udeb/ImageProcessor.o",
		"imageprocessorperf_lib/armv5/urel/ImageProcessor.o"
		])
	t.mustmatch = [
		".*armcc.*-O0.*-g.*--cpu 6.*-Otime.*",
		".*armcc.*-O3.*--cpu 6.*-Otime.*",
		".*OPTION ARMASM has no effect.*",
		".*OPTION_REPLACE ARMASM has no effect.*"
	]
	t.mustnotmatch = [
		".*armcc.*--export_all_vtbl.*"
	]
	t.warnings = 2
	t.run()
	
	t.name = "mmp_option_gcce_linkeroption_gcce"
	t.command = "sbs -b smoke_suite/test_resources/mmp/options/bld.inf -c arm.v5.urel.gcce4_4_1.release_gcce -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/gcce/urel/test.exe",
	]
	t.mustmatch = []
	t.mustmatch_singleline = [
		".*g\+\+.*-c.*-O3.*-fvisibility-inlines-hidden.*",
		".*g\+\+.* -Wl,--verbose -Wl,-pie .*"
	]
	t.mustnotmatch = [
		".*g\+\+.*-c.* -Wl,--verbose -Wl,-pie .*"
	]
	t.warnings = 0 
	t.run()
	
	# LINKEROPTION CW can impact DLL (and variants), EXE and LIB TARGETTYPEs in different ways
	# We ensure we have enough build coverage to cover all linker calls constructed in the win32 FLM
	t.name = "mmp_option_cw_linkeroption_cw"
	t.command = "sbs -b smoke_suite/test_resources/mmp/options/bld.inf -c winscw_urel -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/winscw/urel/test.exe",
	]
	t.mustmatch = []
	t.mustmatch_singleline = []
	t.countmatch = [
		[".*mwccsym2.*-relax_pointers.*-O2", 5],
		[".*mwldsym2.*-zerobss.*-export none", 2],
		[".*mwldsym2.*-zerobss.*-fold all", 2]
	]	
	t.warnings = 0
	t.run()
	
	t.countmatch = []
	
	t.name = "mmp_debuglibrary"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp3/bld.inf -c armv5 -c winscw -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/tbm.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/tbm.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/tbm.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/tbm.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oom.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/t_oom.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oom.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/t_oom.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/dfpaeabi_vfpv2.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/dfpaeabi_vfpv2.dll.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/dfpaeabi_vfpv2.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/dfpaeabi_vfpv2.dll.map",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oom.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_oom.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_oom.exe"
		]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp3/bld.inf", [
		"tbm_exe/armv5/udeb/tbm.o",
		"tbm_exe/armv5/urel/tbm.o",
		"t_oom_exe/armv5/udeb/t_oom.o",
		"t_oom_exe/armv5/urel/t_oom.o",
		"dfpaeabi_vfpv2_dll/armv5/udeb/dfpaeabi.o",
		"dfpaeabi_vfpv2_dll/armv5/urel/dfpaeabi.o",
		"t_oom_exe/winscw/udeb/t_oom.o",
		"t_oom_exe/winscw/udeb/t_oom_UID_.o",
		"t_oom_exe/winscw/urel/t_oom.o",
		"t_oom_exe/winscw/urel/t_oom_UID_.o"
		])
	t.mustmatch = [
		".*armlink.*udeb/eexe.lib.*-o.*armv5/udeb/t_oom.exe.sym.*euser.dso.*efsrv.dso.*estor.dso.*euser.dso.*",
		".*armlink.*urel/eexe.lib.*-o.*armv5/urel/t_oom.exe.sym.*euser.dso.*efsrv.dso.*euser.dso.*",
		".*mwldsym2.*udeb/eexe.lib.*euser.lib.*efsrv.lib.*estor.lib.*euser.lib.*-o.*winscw/udeb/t_oom.exe.*",
		".*mwldsym2.*urel/eexe.lib.*euser.lib.*efsrv.lib.*euser.lib.*-o.*winscw/urel/t_oom.exe.*"
		]
	t.mustnotmatch = []
	t.warnings = 0
	t.run()
	
	t.name = "mmp_basedefault"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp4/group/bld.inf -c winscw"
	t.targets = [			
		"$(EPOCROOT)/epoc32/release/winscw/udeb/d_newldd.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/urel/d_newldd.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/d_lddturnaroundtimertest.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/urel/d_lddturnaroundtimertest.ldd",
		"$(EPOCROOT)/epoc32/release/winscw/urel/d_lddturnaroundtimertest.ldd.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_sharedio3.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_sharedio3.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_sharedio3.exe.map",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/t_rbuf.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_rbuf.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/t_rbuf.exe.map"
		]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp4/group/bld.inf", [
		"d_newldd_ldd/winscw/udeb/d_newldd.o",
		"d_newldd_ldd/winscw/udeb/d_newldd.UID.CPP",
		"d_newldd_ldd/winscw/udeb/d_newldd_UID_.o",
		"d_newldd_ldd/winscw/urel/d_newldd.o",
		"d_newldd_ldd/winscw/urel/d_newldd.UID.CPP",
		"d_newldd_ldd/winscw/urel/d_newldd_UID_.o",
		"d_newldd_ldd/winscw/udeb/t_new_classes.o",
		"d_newldd_ldd/winscw/urel/t_new_classes.o",
		"d_lddturnaroundtimertest_ldd/winscw/udeb/d_lddturnaroundtimertest.o",
		"d_lddturnaroundtimertest_ldd/winscw/udeb/d_lddturnaroundtimertest.UID.CPP",
		"d_lddturnaroundtimertest_ldd/winscw/udeb/d_lddturnaroundtimertest_UID_.o",
		"d_lddturnaroundtimertest_ldd/winscw/urel/d_lddturnaroundtimertest.o",
		"d_lddturnaroundtimertest_ldd/winscw/urel/d_lddturnaroundtimertest.UID.CPP",
		"d_lddturnaroundtimertest_ldd/winscw/urel/d_lddturnaroundtimertest_UID_.o",
		"t_sharedio3_exe/winscw/udeb/t_sharedio.o",
		"t_sharedio3_exe/winscw/udeb/t_sharedio3.UID.CPP",
		"t_sharedio3_exe/winscw/udeb/t_sharedio3_UID_.o",
		"t_sharedio3_exe/winscw/urel/t_sharedio.o",
		"t_sharedio3_exe/winscw/urel/t_sharedio3.UID.CPP",
		"t_sharedio3_exe/winscw/urel/t_sharedio3_UID_.o",
		"t_rbuf_exe/winscw/udeb/t_rbuf.o",
		"t_rbuf_exe/winscw/udeb/t_rbuf.UID.CPP",
		"t_rbuf_exe/winscw/udeb/t_rbuf_UID_.o",
		"t_rbuf_exe/winscw/urel/t_rbuf.o",
		"t_rbuf_exe/winscw/urel/t_rbuf.UID.CPP",
		"t_rbuf_exe/winscw/urel/t_rbuf_UID_.o"
		])
	t.mustmatch = []
	t.run()
	
	# Test keywords: version, firstlib, nocompresstarget
	t.name = "mmp_version_firstlib_nocompresstarget"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp5/bld.inf -c armv5"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/fuzzv5.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/fuzzv5.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/fuzzlib.lib",
		"$(EPOCROOT)/epoc32/release/armv5/urel/fuzzlib.lib"
		]
	t.addbuildtargets("smoke_suite/test_resources/mmp/mmp5/bld.inf", [
		"fuzzv5_exe/armv5/udeb/fuzzv5.o",
		"fuzzv5_exe/armv5/urel/fuzzv5.o",
		"fuzzlib_lib/armv5/udeb/uc_exe_.cpp",
		"fuzzlib_lib/armv5/urel/uc_exe_.cpp",
		"fuzzlib_lib/armv5/udeb/uc_exe_.o",
		"fuzzlib_lib/armv5/urel/uc_exe_.o",
		])
	t.run()

	t.name = "mmp_diagsuppress_armlibs"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp6_7/bld.inf -c armv5 -k -p diagsuppress.mmp -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/diagsuppress_test.dll",
		"$(EPOCROOT)/epoc32/release/armv5/urel/diagsuppress_test.dll",
		]
	t.mustmatch = [
					"--diag_suppress 6780",
					"--diag_suppress 6331"
					]
	t.run()
	
	t.name = "mmp_diagsuppress_no_armlibs"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp6_7/bld.inf -c armv5 -k -p diagsuppress_noarmlibs.mmp -f-"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/diagsuppress_noarmlibs_test.dll",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/diagsuppress_noarmlibs_test.dll"
		]
	t.mustmatch = ["--diag_suppress 6331"]
	t.mustnotmatch = ["--diag_suppress 6780"]
	t.run()

	# Test keyword: version
	t.name = "mmp_version_keyword"
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp8/bld.inf"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_mmp_version.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_mmp_version.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test_mmp_version.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/test_mmp_version.exe"
		]
	t.mustmatch = []
	t.mustnotmatch = []
	t.warnings = 2
	t.run()

	# Test keyword: armfpu softvfp|vfpv2
	# Both armv5 RVCT and GCCE builds are covered, as they differ in behaviour.
	t.name = "mmp_armfpu_softvfp_rvct"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -p armfpu_soft.mmp -c armv5_urel -f-"			
	t.targets = []
	t.mustmatch = ["--fpu softvfp", "--fpu=softvfp"]
	t.mustnotmatch = ["--fpu vfpv2", "--fpu softvfp\+", "--fpu=vfpv2", "--fpu=softvfp\+"]
	t.warnings = 0
	t.run()
		
	t.name = "mmp_armfpu_vfpv2_rvct"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -c armv5_urel REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -p armfpu_vfpv2.mmp -c armv5_urel -f-"

	t.mustmatch = ["--fpu vfpv2", "--fpu=vfpv2"]
	t.mustnotmatch = ["--fpu softvfp", "--fpu=softvfp"]	
	t.run()
	
	t.name = "mmp_armfpu_softvfp+vfpv2_rvct"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -c armv5_urel REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -p \"armfpu_soft+vfpv2.mmp\" -c armv5_urel -f-"

	t.mustmatch = ["--fpu softvfp\+vfpv2", "--fpu=vfpv2"]
	t.mustnotmatch = ["--fpu vfpv2", "--fpu softvfp ", "--fpu=softvfp"]
	t.run()

	t.name = "mmp_armfpu_softvfp+vfpv2_gcce"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf  -c armv5_urel_gcce4_3_2 REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld.inf -c armv5_urel_gcce4_3_2 -f-"
	t.countmatch = [
		["-mfloat-abi=soft", 3],
		["--fpu=softvfp", 3] # gcce doesn't vary according to ARMFPU currently
	]
	t.mustmatch = []
	t.mustnotmatch = ["--fpu=vfpv2", "--fpu=softvfp\+"]
	t.run()
	
	t.name = "mmp_armfpu_softvfp+vfpv3_rvct"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld2.inf -c arm.v5.urel.rvct4_0 REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld2.inf -c arm.v5.urel.rvct4_0 -f- --mo=-n"
	t.countmatch = [
		["elf2e32.*--fpu=vfpv3", 1],
		["armcc.*--fpu.softvfp\+vfpv3", 1]
	]
	t.mustmatch = []
	t.mustnotmatch = ["--fpu=vfpv2", "--fpu=softvfp\+"]
	t.run()
	
	t.name = "mmp_armfpu_softvfp+vfpv3_gcce"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld2.inf  -c armv5_urel_gcce4_4_1 REALLYCLEAN &&" \
			+ " sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp9_10/bld2.inf -c armv5_urel_gcce4_4_1 -f- --mo=-n"
	t.countmatch = [
		["g\+\+.*-mfloat-abi=soft", 1],
		["elf2e32.*--fpu=softvfp", 1] # gcce doesn't vary according to ARMFPU currently
	]
	t.mustmatch = []
	t.mustnotmatch = ["--fpu=vfpv2", "--fpu=softvfp\+"]
	t.run()
	
	# Test keywords: compresstarget, nocompresstarget, bytepaircompresstarget, inflatecompresstarget
	t.name = "mmp_byte_compression_target_keywords"
	t.command = "sbs -b $(SBS_HOME)/test/smoke_suite/test_resources/mmp/mmp11/bld.inf -c armv5_urel -f-"
	t.mustmatch_singleline = [
		"elf2e32.*--output.*\/compress\.exe.*--compressionmethod=inflate",
		"elf2e32.*--output.*\/nocompress\.exe.*--uncompressed",
		"elf2e32.*--output.*\/bytepaircompress\.exe.*--compressionmethod=bytepair",
		"elf2e32.*--output.*\/inflatecompress\.exe.*--compressionmethod=inflate",
		"elf2e32.*--output.*\/combinedcompress\.exe.*--compressionmethod=bytepair",		
		"COMPRESSTARGET keyword in .*combinedcompresstarget.mmp overrides earlier use of NOCOMPRESSTARGET",
		"INFLATECOMPRESSTARGET keyword in .*combinedcompresstarget.mmp overrides earlier use of COMPRESSTARGET",
		"BYTEPAIRCOMPRESSTARGET keyword in .*combinedcompresstarget.mmp overrides earlier use of INFLATECOMPRESSTARGET"
	]
	t.countmatch = []
	t.mustnotmatch = []
	t.warnings = 3
	t.run()

	# Test keyword: APPLY
	t.name = "mmp_apply"
	t.command = "sbs -b smoke_suite/test_resources/mmp/apply/bld.inf -f- -k --configpath=test/config"
	t.targets = [
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_mmp_apply.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_mmp_apply.exe",
		"$(EPOCROOT)/epoc32/release/winscw/urel/test_mmp_apply.exe",
		"$(EPOCROOT)/epoc32/release/winscw/udeb/test_mmp_apply.exe"
		]
	t.mustmatch_singleline = ["-DAPPLYTESTEXPORTEDVAR",
	                          "-DAPPLYTESTAPPENDCDEFS",
	                          "-DSINGLE=1",
	                          "-DDOUBLE"]
	t.countmatch = [["<error.*APPLY unknown variant 'no_such_var'", 2],
				    ["<error.*MACRO names cannot start with a digit '2'", 2]]
	t.errors = 2 # no_such_var for armv5 and winscw
	t.errors += 2 # macro '2' error for armv5 and winscw
	t.warnings = 0
	t.returncode = 1
	t.run()

	# Test keyword: EPOCNESTEDEXCEPTIONS
	t.name = "mmp_epocnestedexceptions"
	t.command = "sbs -b smoke_suite/test_resources/mmp/epocnestedexceptions/bld.inf -c armv5_udeb -f-"

	# When EPOCNESTEDEXCEPTIONS is specified in the MMP file, a different static
	# run-time library should be used.
	t.mustmatch_singleline = ["usrt_nx_\d_\d\.lib"]
	t.mustnotmatch = ["usrt._.."]

	t.countmatch = []

	# The new static run-time libraries don't yet exist.
	t.errors = 1
	t.warnings = 1
	t.targets = []

	t.run()
	
	# Test keyword: DOCUMENT
	t.name = "mmp_keyword_document"
	# Note: in t.command, the makefile is cat'd through sed to remove the .DEFAULT double-colon rule's <warning> tag to ensure that t.run succeeds.
	t.command = "sbs -b smoke_suite/test_resources/mmp/mmp1/group/bld.inf -c armv5 reallyclean; " + \
				"sbs -b smoke_suite/test_resources/mmp/mmp1/group/bld.inf --no-depend-generate -c armv5_urel -m ${SBSMAKEFILE}; " + \
				"cat ${SBSMAKEFILE}_all.default"
	
	t.mustmatch_singleline = ["DOCUMENT:=.*test/smoke_suite/test_resources/mmp/mmp1/src/file01\.txt\\s+.*test/smoke_suite/test_resources/mmp/mmp1/src/file02\.txt"]
	t.mustnotmatch = []
	t.countmatch = []
	
	t.errors = 0
	t.warnings = 0
	t.returncode = 0
	t.targets = []
	
	t.run()
	
	t.name = "mmp_keywords"
	t.print_result()
	return t
Пример #54
0
def run():
    t = SmokeTest()
    t.name = "resource"
    t.command = "sbs  -b smoke_suite/test_resources/simple_gui/Bld.inf RESOURCE"
    t.targets = [
        "$(EPOCROOT)/epoc32/data/z/resource/apps/helloworld.mbm",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/helloworld.mbm",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/helloworld.mbm",
        "$(EPOCROOT)/epoc32/include/HelloWorld.rsg",
        "$(EPOCROOT)/epoc32/data/z/resource/apps/HelloWorld.rsc",
        "$(EPOCROOT)/epoc32/data/z/private/10003a3f/apps/HelloWorld_reg.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/HelloWorld.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/HelloWorld.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/private/10003a3f/apps/HelloWorld_reg.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/private/10003a3f/apps/HelloWorld_reg.rsc"
    ]

    t.addbuildtargets('smoke_suite/test_resources/simple_gui/Bld.inf', [
        "helloworld_exe/helloworld.mbm_bmconvcommands",
        "HelloWorld_exe/HelloWorld_HelloWorld.rsc.rpp",
        "HelloWorld_exe/HelloWorld_HelloWorld.rsc.d",
        "HelloWorld_reg_exe/HelloWorld_reg_HelloWorld_reg.rsc.rpp",
        "HelloWorld_reg_exe/HelloWorld_reg_HelloWorld_reg.rsc.d"
    ])

    t.mustnotmatch = ["HelloWorld.rss.* warning: trigraph"]

    t.run()

    t.name = "no_depend_gen_resource"
    t.usebash = True
    t.description = """Check that dependent resources still build correctly even when we turn dependency generation off.  This
			    test cannot really do this reliably, if you think about it, since it can't force make to try building resources
			    in the 'wrong' order.  What it does attempt is to check that 
			    the ultimately generated dependency file is ok.
			    N.B.  It also attempts to ensure that the dependency file is 'minimal'  i.e. that it only references .mbg and .rsg files
			    that might come from other parts of the same build.  This is important for performance in situations where --no-depend-generate
			    is used because the weight of 'complete' dependency information would overwhelm make.
			 """
    buildLocation = ReplaceEnvs(
        "$(EPOCROOT)/epoc32/build/") + BldInfFile.outputPathFragment(
            'smoke_suite/test_resources/resource/group/bld.inf')
    res_depfile = buildLocation + "/dependentresource_/dependentresource_dependentresource.rsc.d"

    t.targets = [
        "$(EPOCROOT)/epoc32/data/z/resource/anotherresource/testresource.r01",
        "$(EPOCROOT)/epoc32/data/z/resource/anotherresource/testresource.rsc",
        "$(EPOCROOT)/epoc32/data/z/resource/dependentresource/dependentresource.rsc",
        "$(EPOCROOT)/epoc32/data/z/resource/testresource/testresource.r01",
        "$(EPOCROOT)/epoc32/include/testresource.hrh",
        "$(EPOCROOT)/epoc32/include/testresource.rsg",
        "$(EPOCROOT)/epoc32/include/onelang.rsg",
        "$(EPOCROOT)/epoc32/release/armv5/urel/testresource.exe",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/anotherresource/testresource.r01",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/anotherresource/testresource.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/dependentresource/dependentresource.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/anotherresource/testresource.r01",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/anotherresource/testresource.rsc",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/dependentresource/dependentresource.rsc",
        res_depfile
    ]

    t.addbuildtargets('smoke_suite/test_resources/resource/group/bld.inf', [
        "dependentresource_/dependentresource_dependentresource.rsc",
        "testresource_/testresource_dependentresource.r01",
        "testresource_/testresource_dependentresource.rsc",
        "testheader_/testheader_testresource_sc.rsg.d",
        "testheader_/testheader_testresource_sc.rsg.rpp",
        "testresource_/testresource_testresource.r02.rpp",
        "onelang_/onelang_onelang_sc.rsg.rpp",
        "testresource_/testresource_testresource.rsc.rpp"
    ])

    t.command = "sbs -b smoke_suite/test_resources/resource/group/bld.inf  -c armv5_urel -c winscw_urel reallyclean ; sbs --no-depend-generate -j 16 -b smoke_suite/test_resources/resource/group/bld.inf -c armv5_urel -c winscw_urel -f ${{SBSLOGFILE}} -m ${{SBSMAKEFILE}} && grep 'epoc32.include.test[^ ]*.rsg' {0} && {{ X=`md5sum $(EPOCROOT)/epoc32/release/winscw/urel/z/resource/anotherresource/testresource.rsc` && Y=`md5sum $(EPOCROOT)/epoc32/data/z/resource/testresource/testresource.rsc` && [ \"${{X%% *}}\" != \"${{Y%% *}}\" ] ; }}  && wc -l {1} ".format(
        res_depfile, res_depfile)

    t.mustnotmatch = []

    t.mustmatch = [
        "[23] .*.dependentresource_.dependentresource_dependentresource.rsc.d"
    ]

    t.run()

    t.name = "resource_corner_cases_reallyclean"
    t.usebash = True
    t.description = """ Additional corner cases for resources:
						 1) Use of "TARGETTYPE none" but not "TARGET" mmp keyword.
						 2) Use of a resource with no LANG. """

    t.targets = []

    t.command = "sbs -b smoke_suite/test_resources/resource/group/bld2.inf -c armv5_urel -c winscw_urel reallyclean"
    t.mustnotmatch = []
    t.mustmatch = []
    t.run()

    t.name = "resource_corner_cases"
    t.usebash = True
    t.description = """ Additional corner cases for resources:
						 1) Use of "TARGETTYPE none" but not "TARGET" mmp keyword.
						 2) Use of a resource with no LANG. """

    buildLocation = ReplaceEnvs(
        "$(EPOCROOT)/epoc32/build/") + BldInfFile.outputPathFragment(
            'smoke_suite/test_resources/resource/group/bld2.inf')
    rsc_file = buildLocation + "/testresource_/testresource_testresource.rsc"

    t.targets = [
        "$(EPOCROOT)/epoc32/data/z/resource/apps/notargetkeyword.mbm",
        "$(EPOCROOT)/epoc32/release/winscw/udeb/z/resource/apps/notargetkeyword.mbm",
        "$(EPOCROOT)/epoc32/release/winscw/urel/z/resource/apps/notargetkeyword.mbm",
        rsc_file
    ]

    t.command = "sbs -b smoke_suite/test_resources/resource/group/bld2.inf -c armv5_urel -c winscw_urel"
    t.mustnotmatch = []
    t.mustmatch = []
    t.run()

    t.name = "resource_rsg_casefolding_fail"
    t.command = "sbs -b smoke_suite/test_resources/resource/rsg_casefolding/bld.inf RESOURCE"
    t.targets = []

    t.warnings = 1
    t.errors = 3
    t.returncode = 1
    t.run("linux")

    t.name = "resource_rsg_casefolding_pass"
    t.command = "sbs -b smoke_suite/test_resources/resource/rsg_casefolding/bld.inf --use-rsg-casefolding RESOURCE"
    t.targets = []

    t.warnings = 0
    t.errors = 0
    t.returncode = 0
    t.run("linux")

    t.name = 'resource'
    t.print_result()
    return t
Пример #55
0
def run():
    t = SmokeTest()
    t.logfileOption = lambda: ""
    t.id = "0074a"
    t.name = "configpath"
    t.description = """Test --configpath option for sbs. Specify two remote
			locations and use the variants in those folders along with ones in
			each of the default folders."""

    # the variants here affect compile steps so we only need to see a single compile
    # to know whether the variant is doing its thing or not.
    t.addbuildtargets("smoke_suite/test_resources/simple/bld.inf",
                      ["test_/armv5/udeb/test.o"])

    result = SmokeTest.PASS

    # the extra config folders are
    # smoke_suite/test_resources/configpathtest/v{2,3}
    sbshome = os.environ["SBS_HOME"].replace("\\", "/")

    aFolder = sbshome + "/test/smoke_suite/test_resources/configpathtest/v2"
    bFolder = sbshome + "/test/smoke_suite/test_resources/configpathtest/v3"

    common = "sbs -b smoke_suite/test_resources/simple/bld.inf " + \
      "-c armv5.configpathtest1.configpathtest2.configpathtest3"

    # run the command using the built-in default systemConfig
    t.command = common + " --configpath=" + aFolder + os.pathsep + bFolder + \
      " -f -"

    t.mustmatch = [
        ".*armv5_udeb.configpathtest1.configpathtest2.configpathtest3.*",
        ".*armv5_urel.configpathtest1.configpathtest2.configpathtest3.*",
        ".*Duplicate variant 'configpathtest3'.*", ".*-DTESTPASSED.*",
        ".*-DOSVARIANT95WASAPPLIED.*"
    ]
    t.mustnotmatch = [".*sbs: error: Unknown variant.*", ".*-DTESTFAILED.*"]
    # Duplicate variant is Info not Warn
    t.warnings = 0
    t.run()

    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    # run the command again using a systemConfig from $HOME/.sbs_init.xml
    # and the configpath as two separate options.
    t.usebash = True
    homedir = sbshome + "/test/smoke_suite/test_resources/configpathtest/home"
    t.command = "export HOME=" + homedir + "; " + common + \
      " --configpath=" + aFolder + " --configpath=" + bFolder + " -f -"
    t.id = "0074b"
    t.mustmatch = [
        ".*armv5_udeb.configpathtest1.configpathtest2.configpathtest3.*",
        ".*armv5_urel.configpathtest1.configpathtest2.configpathtest3.*",
        ".*Duplicate variant 'configpathtest3'.*"
    ]
    t.mustnotmatch = [".*sbs: error: Unknown variant.*"]
    t.run()

    if t.result == SmokeTest.FAIL:
        result = SmokeTest.FAIL

    # Clean
    t.mustmatch = []
    t.targets = []
    t.id = "0074c"
    t.name = "CLEAN"
    t.command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c armv5 " + \
      "REALLYCLEAN"
    t.run()  # Does not contribute to results

    t.id = "74"
    t.name = "configpath"
    t.result = result
    t.print_result()
    return t
Пример #56
0
def run():
	t = SmokeTest()
	t.usebash = True
	result = SmokeTest.PASS

	mmpcount = 10 # how many mmps in this parallel parsing test
	
	target_templ = [
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe.map",
		"$(EPOCROOT)/epoc32/release/armv5/udeb/test_pp#.exe.sym",
		"$(EPOCROOT)/epoc32/release/armv5/urel/test_pp#.exe.sym"
	]

	targets = []

	# Test appropriate startup script for platform:
	sbs_script="sbs"
	if t.onWindows:
		sbs_script="sbs.bat"

	# Build up target list for 10 similar executables
	for num in range(1,mmpcount):
		for atarget in target_templ:
			targets.append(atarget.replace('pp#','pp'+ str(num)))

	t.name = "parallel_parsing"
	t.description = """This test covers parallel parsing."""
	t.command=("mkdir -p $(EPOCROOT)/epoc32/build && cd $(SBS_HOME)/test/smoke_suite/test_resources/pp/ && " 
	"{0} --command=$(SBS_HOME)/test/smoke_suite/test_resources/pp/ppbldinf_commandfile -c armv5 -c winscw " 
	"--pp=on --noexport -m {1} -f - | grep progress ".format(sbs_script, "${SBSMAKEFILE}"))
	t.targets = targets
	t.mustmatch =  [
		".*<progress:start object_type='makefile' task='makefile_generation'.*"
	]
	t.mustnotmatch = [
		".*<recipe .*name='makefile_generation_export.*",
		".*<error[^><]*>.*"
	]
	t.warnings = 0
	t.run()

	t.name = "parallel_parsing_missing_includes_in_bld_inf"
	t.description = """ Ensure errors from parallel parsing are recorded by the top level Raptor. """
	t.command=("{0} -s smoke_suite/test_resources/pp/sys_def.xml -c armv5 -k --pp=on reallyclean > /dev/null 2>&1; "
	"{0} -s smoke_suite/test_resources/pp/sys_def.xml -c armv5 -k --pp=on".format(sbs_script))
	t.targets = []
	t.mustmatch = [
		 "sbs: error: .*cpp.*test/smoke_suite/test_resources/pp/test01/bld.inf.*this_file_does_not_exist.inf: No such file or directory",
		("sbs: error: Preprocessor exception.*Errors in .*test/smoke_suite/test_resources/pp/test01/bld.inf'' " 
		 ": in command.*cpp.*component.*test/smoke_suite/test_resources/pp/test01/bld.inf")
									
					]
	t.mustnotmatch = []
	t.warnings = -1
	t.errors = -1
	t.returncode = 1
	t.run()

	t.name = "parallel_parsing"
	t.print_result()
	return t
Пример #57
0
def run():
	result = SmokeTest.PASS
	t = SmokeTest()
	t.id = "0018a"
	t.name = "temclean"
	t.command = "sbs -b smoke_suite/test_resources/tem/bldclean.inf -c armv5 CLEAN"
	t.targets = [
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded",
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
		]
	t.missing = 2
	t.warnings = 1
	t.returncode = 0
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL
	
	
	t.id = "0018b"
	t.name = "temtest"
	t.command = "sbs -b smoke_suite/test_resources/tem/bld.inf -c armv5"
	t.targets = [
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded"
		]
	t.warnings = 2
	t.missing = 0
	t.returncode = 1
	t.mustmatch = [ "repeated call to TEM with same values.* Stop\." ]
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL


	t.id = "0018c"
	t.name = "temclean2"
	t.command = "sbs -b smoke_suite/test_resources/tem/bldclean.inf -c armv5 CLEAN"
	t.targets = [
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded",
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
		]
	t.missing = 2
	t.warnings = 1
	t.returncode = 0
	t.mustmatch = []
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL


	t.id = "0018d"
	t.name = "badtem"
	t.command = "sbs -b smoke_suite/test_resources/tem/bad_bld.inf -c armv5"
	t.targets = [
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
		]
	t.warnings = 3
	t.missing = 0
	t.returncode = 1
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL


	t.id = "0018e"
	t.name = "temclean3"
	t.command = "sbs -b smoke_suite/test_resources/tem/bldclean.inf -c armv5 CLEAN"
	t.targets = [
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_succeeded",
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
		]
	t.missing = 2
	t.warnings = 1
	t.returncode = 0
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL


	t = CheckWhatSmokeTest()
	t.id = "0018f"
	t.name = "temwhat"
	t.command = "sbs -b smoke_suite/test_resources/simple_extension/bld.inf --what"
	t.output_expected_only_once = True	
	t.stdout = [
		# exports
		'$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/clean.mk',
		'$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/clean.meta',
		'$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/build.mk',
		'$(EPOCROOT)/epoc32/tools/makefile_templates/sbsv2test/build.meta',
		# release tree built
		'$(EPOCROOT)/epoc32/release/armv5/udeb/simple_extension.txt',
		'$(EPOCROOT)/epoc32/release/armv5/urel/simple_extension.txt',
		'$(EPOCROOT)/epoc32/release/winscw/udeb/simple_extension.txt',
		'$(EPOCROOT)/epoc32/release/winscw/urel/simple_extension.txt'
	]
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL


	t = SmokeTest()
	t.id = "0018g"
	t.name = "badtem2"
	t.command = "sbs -b smoke_suite/test_resources/tem/bad2_bld.inf -c armv5"
	t.targets = [
		"$(EPOCROOT)/epoc32/raptor_smoketest_tem_failed"
		]
	t.warnings = 3
	t.returncode = 1
	t.run()
	if t.result == SmokeTest.FAIL:
		result = SmokeTest.FAIL

	t.id = "18"
	t.name = "temtest"
	t.result = result
	t.print_result()
	return t
Пример #58
0
def run():
    t = SmokeTest()
    t.usebash = True
    result = SmokeTest.PASS

    abs_epocroot = os.path.abspath(os.environ["EPOCROOT"])
    cwd = os.getcwd().replace("\\", "/")

    relative_epocroot = os.path.relpath(abs_epocroot.replace("\\", "/"), cwd)

    description = """This tests the whatcomp filter.  As a byproduct it uses (and thus smoke-tests) sbs_filter.py"""
    command = "sbs -b smoke_suite/test_resources/simple/bld.inf -c {0} -m ${{SBSMAKEFILE}} -f ${{SBSLOGFILE}} what  && " + \
       "EPOCROOT='{0}' sbs_filter --filters FilterWhatComp < ${{{{SBSLOGFILE}}}} &&".format(relative_epocroot) + \
       "EPOCROOT='{0}' sbs_filter --filters FilterWhatComp < ${{{{SBSLOGFILE}}}}".format(abs_epocroot)
    targets = []
    buildtargets = []

    mustmatch_pre = [
        "-- abld -w",
        ".*Chdir .*/smoke_suite/test_resources/simple.*",
        relative_epocroot + "/epoc32/release/armv5/urel/test.exe",
        relative_epocroot + "/epoc32/release/armv5/urel/test.exe.map",
        abs_epocroot + "/epoc32/release/armv5/urel/test.exe",
        abs_epocroot + "/epoc32/release/armv5/urel/test.exe.map",
    ]

    if os.sep == '\\':
        mustmatch = [
            i.replace("\\", "\\\\").replace("/", "\\\\") for i in mustmatch_pre
        ]
    else:
        mustmatch = mustmatch_pre

    mustnotmatch = ["error: no (CHECK|WHAT) information found"]
    warnings = 0

    t.name = "whatcomp_basic"
    t.description = description
    t.command = command.format("arm.v5.urel.gcce4_4_1")
    t.targets = targets
    t.mustmatch = mustmatch
    t.mustnotmatch = mustnotmatch
    t.warnings = warnings
    t.run()

    t.name = "whatcomp_component_repeated"
    t.description = """
			It is possible for what information about a component to not be grouped
			(i.e. for multiple whatlogs tags relating to a single component to be 
			interspersed with whatlog tags relating to other components).  
			Raptor must cope with that and must *not* report missing files under 
			the wrong component name."""
    t.command = "sbs_filter --filters=FilterWhatComp < smoke_suite/test_resources/logexamples/what_component_repeated.log"
    t.targets = []
    t.mustmatch = []
    t.mustmatch_multiline = [
        "Chdir y:.ext.app.emailwizard.*epoc32.data.something.*" +
        "Chdir y:.sf.mw.gsprofilesrv.ftuwizardmodel.*epoc32.release.armv5.something.*"
        + "Chdir y:.ext.app.emailwizard.*epoc32.data.something_else"
    ]

    t.mustnotmatch = []
    t.warnings = 0
    t.run()

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