summaryrefslogtreecommitdiff
path: root/tests/test_GitRepository.py
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2012-06-30 09:32:43 +0200
committerGuido Günther <agx@sigxcpu.org>2012-06-30 09:32:43 +0200
commit41482a3b5cd36ac7b1fd53079f2a05e5b4fbc99e (patch)
tree725dddb53d0d5ed78e9419ccc8dc09ca1bb2161b /tests/test_GitRepository.py
parent18fc69803c3b89d0ce7e502b3aa610dce8bfeac1 (diff)
downloadgit-buildpackage-41482a3b5cd36ac7b1fd53079f2a05e5b4fbc99e.tar.gz
git-buildpackage-41482a3b5cd36ac7b1fd53079f2a05e5b4fbc99e.tar.bz2
git-buildpackage-41482a3b5cd36ac7b1fd53079f2a05e5b4fbc99e.zip
tests: test GitRepository.get_commit_info()
Diffstat (limited to 'tests/test_GitRepository.py')
-rw-r--r--tests/test_GitRepository.py21
1 files changed, 21 insertions, 0 deletions
diff --git a/tests/test_GitRepository.py b/tests/test_GitRepository.py
index 121be901..84619040 100644
--- a/tests/test_GitRepository.py
+++ b/tests/test_GitRepository.py
@@ -340,6 +340,27 @@ def test_get_commits():
True
"""
+
+def test_get_commit_info():
+ """
+ Test inspecting commits
+
+ Methods tested:
+ - L{gbp.git.GitRepository.get_commit_info}
+
+ >>> import gbp.git
+ >>> repo = gbp.git.GitRepository(repo_dir)
+ >>> info = repo.get_commit_info('HEAD')
+ >>> info['id']
+ 'HEAD'
+ >>> info['body']
+ ['']
+ >>> info['subject']
+ 'foo'
+ >>> '@' in info['email']
+ True
+ """
+
def test_mirror_clone():
"""
Mirror a repository