Mercurial > wikked
diff tests/mock.py @ 497:36c3e9b1d1e3
cm: Upgrade all dependencies and fix deprecation issues.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Sat, 06 Jun 2020 22:24:38 -0700 |
parents | 2027ab79f006 |
children |
line wrap: on
line diff
--- a/tests/mock.py Wed Nov 07 23:19:43 2018 -0800 +++ b/tests/mock.py Sat Jun 06 22:24:38 2020 -0700 @@ -5,7 +5,7 @@ import io from collections import deque from contextlib import closing -from configparser import SafeConfigParser +from configparser import ConfigParser from wikked.fs import FileSystem from wikked.db.base import Database from wikked.indexer.base import WikiIndex @@ -59,12 +59,12 @@ os.path.dirname(__file__), '..', 'wikked', 'resources', 'defaults.cfg') - config = SafeConfigParser() - config.readfp(open(default_config_path)) + config = ConfigParser() + config.read_file(open(default_config_path)) config.set('wiki', 'root', '/fake/root') if self.config_text: with closing(io.StringIO(self.config_text)) as conf: - config.readfp(conf) + config.read_file(conf) return config