def testDatabase(): # rig:3
    def show(thing):
        print thing
        return thing
    def reportToDb(reporterFunc):
        return reporterFunc({"test_performed":time.time()})
    return pipeline(checkForTestingData(), 
                    readBytes,
		    str.strip,
                    genReporter,
                    reportToDb,
                    show)
def readFromFile(filePath, alternate, mode, *etc): # rig:3 
    '''Failed to open file.'''
    return pipeline(firstGood(readFile(filePath, mode), alternate), *etc)
def readFile(filePath, mode, *etc): # rig:3
    '''Failed to load file'''
    return pipeline(filePath,
                      fpth,
                      partial(loadf, mode),
                      *etc)
def writeLines(filePath, *lines): # rig:3 
    return pipeline(filePath,
                      fpth,
                      partial(loadf, "wt"),
                      partial(writeTo, lines))
def _dbUsageGen(dbHost, finalUserFunc, collection):
    return pipeline(dbHost, establishConnection, useDatabase,
                    partial(getCollectionObj, collection), finalUserFunc)