remove a file from the worker

def runRmFile(self, path, timeout=None, **kwargs):
        """ remove a file from the worker """
        cmd_args = {'path': path, 'logEnviron': self.logEnviron}
        if timeout:
            cmd_args['timeout'] = timeout
        if self.workerVersionIsOlderThan('rmfile', '3.1'):
            cmd_args['dir'] = os.path.abspath(path)
            return self.runRemoteCommand('rmdir', cmd_args, **kwargs)
        return self.runRemoteCommand('rmfile', cmd_args, **kwargs)