From b9d71fa787a2ffb99b6631e4bd6df932a4d4adbb Mon Sep 17 00:00:00 2001 From: Vincent Jacques Date: Thu, 28 Mar 2013 21:05:19 +0100 Subject: [PATCH] Slightly improve coverage :-D --- github/GithubObject.py | 2 +- github/tests/Github_.py | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/github/GithubObject.py b/github/GithubObject.py index 99884297..968926dc 100644 --- a/github/GithubObject.py +++ b/github/GithubObject.py @@ -20,7 +20,7 @@ import GithubException class _NotSetType: def __repr__(self): - return "NotSet" # pragma no cover + return "NotSet" NotSet = _NotSetType() diff --git a/github/tests/Github_.py b/github/tests/Github_.py index 149af2b8..e401a257 100644 --- a/github/tests/Github_.py +++ b/github/tests/Github_.py @@ -17,6 +17,7 @@ import datetime import Framework +import github class Github(Framework.TestCase): def testGetGists(self): @@ -107,3 +108,6 @@ class Github(Framework.TestCase): t = self.g.get_gitignore_template("C++") self.assertEqual(t.name, "C++") self.assertEqual(t.source, "# Compiled Object files\n*.slo\n*.lo\n*.o\n\n# Compiled Dynamic libraries\n*.so\n*.dylib\n\n# Compiled Static libraries\n*.lai\n*.la\n*.a\n") + + def testStringOfNotSet(self): + self.assertEqual(str(github.GithubObject.NotSet), "NotSet")