Issue33.py
1 ############################ Copyrights and license ############################ 2 # # 3 # Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> # 4 # Copyright 2012 Zearin <zearin@gonk.net> # 5 # Copyright 2013 Vincent Jacques <vincent@vincent-jacques.net> # 6 # Copyright 2014 Vincent Jacques <vincent@vincent-jacques.net> # 7 # Copyright 2016 Peter Buckley <dx-pbuckley@users.noreply.github.com> # 8 # Copyright 2018 sfdye <tsfdye@gmail.com> # 9 # # 10 # This file is part of PyGithub. # 11 # http://pygithub.readthedocs.io/ # 12 # # 13 # PyGithub is free software: you can redistribute it and/or modify it under # 14 # the terms of the GNU Lesser General Public License as published by the Free # 15 # Software Foundation, either version 3 of the License, or (at your option) # 16 # any later version. # 17 # # 18 # PyGithub is distributed in the hope that it will be useful, but WITHOUT ANY # 19 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS # 20 # FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more # 21 # details. # 22 # # 23 # You should have received a copy of the GNU Lesser General Public License # 24 # along with PyGithub. If not, see <http://www.gnu.org/licenses/>. # 25 # # 26 ################################################################################ 27 28 from . import Framework 29 30 31 class Issue33(Framework.TestCase): # https://github.com/jacquev6/PyGithub/issues/33 32 def setUp(self): 33 super().setUp() 34 self.repo = self.g.get_user("openframeworks").get_repo("openFrameworks") 35 36 def testOpenIssues(self): 37 self.assertEqual(len(list(self.repo.get_issues())), 338) 38 39 def testClosedIssues(self): 40 self.assertEqual(len(list(self.repo.get_issues(state="closed"))), 950)