summaryrefslogtreecommitdiff
path: root/test/git/test_config.py
diff options
context:
space:
mode:
authorSebastian Thiel <byronimo@gmail.com>2009-12-03 17:43:40 +0100
committerSebastian Thiel <byronimo@gmail.com>2009-12-03 17:43:40 +0100
commit7d00fa4f6cad398250ce868cef34357b45abaad3 (patch)
treefb9c7ab507618f9f55100ac90dd5b617850213cd /test/git/test_config.py
parentc05ef0e7543c2845fd431420509476537fefe2b0 (diff)
downloadgitpython-7d00fa4f6cad398250ce868cef34357b45abaad3.tar.gz
config: implemented get_value method to have a safe way to make general queries to the git configuration, returning a value in the proper type. In a way its not supposed to be used as you should know the type of your configuration option or get an exception otherwise
Diffstat (limited to 'test/git/test_config.py')
-rw-r--r--test/git/test_config.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/git/test_config.py b/test/git/test_config.py
index c2909b8f..4b6c4f11 100644
--- a/test/git/test_config.py
+++ b/test/git/test_config.py
@@ -72,6 +72,8 @@ class TestBase(TestCase):
for option in r_config.options(section):
num_options += 1
val = r_config.get(section, option)
+ val_typed = r_config.get_value(section, option)
+ assert isinstance(val_typed, (bool, long, float, basestring))
assert val
assert "\n" not in option
assert "\n" not in val