from git.repo.base import Repo

def test_open_repo():
  assert len(Repo().branches) > 0

from git.repo.base import Repo
from unittest import TestCase

class TestSequenceFunctions(TestCase):
    def test_open_repo(self):
        self.assertTrue(len(Repo().branches) > 0)

Switch over to pyunit from py.test