1
0
mirror of https://github.com/deadc0de6/dotdrop.git synced 2026-02-06 13:07:59 +00:00

refactor configs to settings for clarity

This commit is contained in:
deadc0de6
2018-06-02 14:56:15 +02:00
parent 0052571d2e
commit ea3cc6663b
4 changed files with 44 additions and 44 deletions

View File

@@ -65,7 +65,7 @@ def create_dir(path):
def load_config(confpath, profile):
'''Load the config file from path'''
conf = Cfg(confpath)
opts = conf.get_configs()
opts = conf.get_settings()
opts['dry'] = False
opts['profile'] = profile
opts['safe'] = True

View File

@@ -37,7 +37,7 @@ class TestConfig(unittest.TestCase):
conf = Cfg(confpath)
self.assertTrue(conf is not None)
opts = conf.get_configs()
opts = conf.get_settings()
self.assertTrue(opts is not None)
self.assertTrue(opts != {})
self.assertTrue(opts['backup'] == self.CONFIG_BACKUP)
@@ -88,7 +88,7 @@ class TestConfig(unittest.TestCase):
self.assertTrue(conf is not None)
# test profile
opts = conf.get_configs()
opts = conf.get_settings()
print(conf.get_profiles())
profiles = conf.get_profiles()
self.assertTrue(pf1key in profiles)