示例#1
0
def addFile(file) :
	if not ".svn" in file :
		addShipDir(os.path.dirname(file))
		if ac.isTestFile(file) or ac.isExampleFile(file) :
			projects.add(file)
		elif ("ramp\\" in file or "TestHarness" in file) :
			testhelpers.add(file)
		else :
			srcs.add(file)
示例#2
0
def addFile(file):
    if not ".svn" in file:
        addShipDir(os.path.dirname(file))
        if ac.isTestFile(file) or ac.isExampleFile(file):
            projects.add(file)
        elif ("ramp\\" in file or "TestHarness" in file):
            testhelpers.add(file)
        else:
            srcs.add(file)
示例#3
0
def makeProjectName(project) :
	noext = os.path.basename(project).rpartition(".")[0] # baz
	if ac.isTestFile(project) : # use dirname to disambiguate
		dirname = project.rpartition("\\")[0].rpartition("\\")[2] # bar
		return "test_"+dirname+"_"+noext # test_bar_baz
	elif noext.startswith("write_"):
		writers.add(noext)
		return noext
	else :
		return "example_"+noext
示例#4
0
def makeProjectName(project):
    noext = os.path.basename(project).rpartition(".")[0]  # baz
    if ac.isTestFile(project):  # use dirname to disambiguate
        dirname = project.rpartition("\\")[0].rpartition("\\")[2]  # bar
        return "test_" + dirname + "_" + noext  # test_bar_baz
    elif noext.startswith("write_"):
        writers.add(noext)
        return noext
    else:
        return "example_" + noext