aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
diff options
context:
space:
mode:
authorGuido Günther <g.guenther@tarent.de>2011-10-28 10:14:34 +0200
committerGuido Günther <agx@sigxcpu.org>2011-10-28 18:48:19 +0200
commit3d80c335ecbac1db0826d9d5d03fe36b92ccf62d (patch)
tree019cec6b207fa181d1b53ceba46c5aded7497888 /tests
parenta4aa2b78c7b68de7058e385fd20dfc53f9699eff (diff)
GitModifier: Don't use self.__dict__.update(locals())
to make pychecker happy
Diffstat (limited to 'tests')
-rw-r--r--tests/test_GitModifier.py23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/test_GitModifier.py b/tests/test_GitModifier.py
new file mode 100644
index 00000000..10188a0e
--- /dev/null
+++ b/tests/test_GitModifier.py
@@ -0,0 +1,23 @@
+# vim: set fileencoding=utf-8 :
+
+"""
+Test L{gbp.git.GitModifier}
+"""
+
+def test_author():
+ """
+ Methods tested:
+ - L{gbp.git.GitModifer.get_author_env}
+ - L{gbp.git.GitModifer.get_comitter_env}
+
+ >>> import gbp.git
+ >>> modifier = gbp.git.GitModifier("foo", "bar")
+ >>> modifier.name
+ 'foo'
+ >>> modifier.email
+ 'bar'
+ >>> modifier.get_author_env()
+ {'GIT_AUTHOR_EMAIL': 'bar', 'GIT_AUTHOR_NAME': 'foo'}
+ >>> modifier.get_committer_env()
+ {'GIT_COMMITTER_NAME': 'foo', 'GIT_COMMITTER_EMAIL': 'bar'}
+ """