diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2009-12-09 21:38:12 +0100 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2009-12-09 21:38:12 +0100 |
commit | a97d21936200f1221d8ddd89202042faed1b9bcb (patch) | |
tree | d545db205d0bd731fc16d19663f7028dabe0f57d /test/git/test_config.py | |
parent | 35057c56ce118e4cbd0584bd4690e765317b4c38 (diff) | |
download | gitpython-a97d21936200f1221d8ddd89202042faed1b9bcb.tar.gz |
config: fixed incorrect handling of default value in get_value
remote.config: SectionConstraint now knows about set_value and get_value which are new to the GitConfigParser
Diffstat (limited to 'test/git/test_config.py')
-rw-r--r-- | test/git/test_config.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/git/test_config.py b/test/git/test_config.py index 6103ab8d..407eb9bd 100644 --- a/test/git/test_config.py +++ b/test/git/test_config.py @@ -8,6 +8,7 @@ from test.testlib import * from git import * import StringIO from copy import copy +from ConfigParser import NoSectionError class TestBase(TestCase): @@ -97,4 +98,7 @@ class TestBase(TestCase): default = "my default value" assert r_config.get_value("doesnt", "exist", default) == default + # it raises if there is no default though + self.failUnlessRaises(NoSectionError, r_config.get_value, "doesnt", "exist") + |