changeset 228:b2c75efad9e4

Renamed the 'ignore' loader key to '-*-ignore-*-'
author Franz Glasner <fzglas.hg@dom66.de>
date Mon, 13 May 2019 09:35:03 +0200
parents f5011eec3b6e
children 8dbaac3ea59b
files configmix/__init__.py tests/test.py
diffstat 2 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/configmix/__init__.py	Sun May 12 18:06:37 2019 +0200
+++ b/configmix/__init__.py	Mon May 13 09:35:03 2019 +0200
@@ -171,7 +171,7 @@
     "conf-toml": _load_toml,
     "javascript": _load_json,
     "json": _load_json,
-    "ignore": _load_ignore,
+    "-*-ignore-*-": _load_ignore,
 }
 """Default associations between file modes and loader functions"""
 
--- a/tests/test.py	Sun May 12 18:06:37 2019 +0200
+++ b/tests/test.py	Mon May 13 09:35:03 2019 +0200
@@ -375,7 +375,7 @@
     def test02_ignore_one_style(self):
         configmix.clear_assoc()
         configmix.set_assoc("*.conf", configmix.get_default_assoc("*.yml"))
-        configmix.set_assoc("*", "ignore", append=True)
+        configmix.set_assoc("*", "-*-ignore-*-", append=True)
 
         cfg = configmix.load(os.path.join(TESTDATADIR, "conf1.ini"),
                              os.path.join(TESTDATADIR, "conf30.conf"))
@@ -386,7 +386,7 @@
         configmix.clear_assoc()
         configmix.set_assoc("*.conf", configmix.get_default_assoc("*.yml"))
         # This inserts at index 0 effectively ignoring all configuration files!
-        configmix.set_assoc("*", "ignore")
+        configmix.set_assoc("*", "-*-ignore-*-")
 
         cfg = configmix.load(os.path.join(TESTDATADIR, "conf1.ini"),
                              os.path.join(TESTDATADIR, "conf30.conf"))