def pathEntryTree(self, tree):
        def makeSomeFiles(pathobj, dirdict):
            pathdict = {}
            for (key, value) in dirdict.items():
                child = pathobj.child(key)
                if isinstance(value, str):
                    pathdict[key] = child
                    child.setContent(value)
                elif isinstance(value, dict):
                    child.createDirectory()
                    pathdict[key] = makeSomeFiles(child, value)
                else:
                    raise ValueError("only strings and dicts allowed as values")
            return pathdict
        base = FilePath(self.mktemp())
        base.makedirs()

        result = makeSomeFiles(base, tree)
        self.replaceSysPath([base.path] + sys.path)
        self.replaceSysModules(sys.modules.copy())
        return result
Create some files in a hierarchy, based on a dictionary describing those
dataset/ETHPy150Open nlloyd/SubliminalCollaborator/libs/twisted/python/test/test_deprecate.py/ImportedModuleAttributeTests.pathEntryTree