def METHOD_NAME(tmpdir, mocker):
    ini_contents = '[main]\nversion = 50.0.0\n\n'
    ini_contents += "[section]\noption = value"
    name = 'spyder'
    path = str(tmpdir)
    def temp(*args, **kwargs):
        return path
    mocker.patch('spyder.config.base', 'get_conf_path')
    inifile = tmpdir.join('{}.ini'.format(name))
    os.makedirs(str(tmpdir.join('app', 'config')))
    inifile2 = tmpdir.join('app', 'config', '{}.ini'.format(name))
    inifile.write(ini_contents + '\n\n')
    inifile2.write(ini_contents + '\n\n')
    return SpyderUserConfig(name=name, path=path, defaults={}, load=True,
                            version='50.0.0', backup=False, raw_mode=True,
                            remove_obsolete=False)