diff options
author | Sebastian Thiel <byronimo@gmail.com> | 2009-10-18 23:15:55 +0200 |
---|---|---|
committer | Sebastian Thiel <byronimo@gmail.com> | 2009-10-18 23:15:55 +0200 |
commit | 9513aa01fab73f53e4fe18644c7d5b530a66c6a1 (patch) | |
tree | b5f9113b04215d1cc31d91fd7a1ef05e3b90c441 /test/git/test_repo.py | |
parent | 657a57adbff49c553752254c106ce1d5b5690cf8 (diff) | |
download | gitpython-9513aa01fab73f53e4fe18644c7d5b530a66c6a1.tar.gz |
Added frame for configuration reader involving a meta class, decorators and tests - most of which still has to be filled out
Diffstat (limited to 'test/git/test_repo.py')
-rw-r--r-- | test/git/test_repo.py | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/test/git/test_repo.py b/test/git/test_repo.py index 87332067..843a4b4e 100644 --- a/test/git/test_repo.py +++ b/test/git/test_repo.py @@ -8,9 +8,11 @@ import os, sys from test.testlib import * from git import * -class TestRepo(object): - def setup(self): - self.repo = Repo(GIT_REPO) +class TestRepo(TestCase): + + @classmethod + def setUpAll(cls): + cls.repo = Repo(GIT_REPO) @raises(InvalidGitRepositoryError) def test_new_should_raise_on_invalid_repo_location(self): @@ -219,3 +221,13 @@ class TestRepo(object): # END handle files assert len(self.repo.untracked_files) == (num_recently_untracked - len(files)) + + def test_config_reader(self): + reader = self.repo.config_reader + assert reader.read_only + + def test_config_writer(self): + for config_level in self.repo.config_level: + writer = self.repo.config_writer(config_level) + assert not writer.read_only + # END for each config level |