def writestate(self, state):
        try:
            f = open(os.path.join(self.sessiondir, "state"), "w")
            f.write("%d %s\n" % (state, coreapi.state_name(state)))
            f.close()
        except Exception, e:
            self.warn("Error writing state file: %s" % e)
Test the ability to retrieve a commit's statuses.
dataset/ETHPy150Open coreemu/core/daemon/core/session.py/Session.writestate--crossover with--dataset/ETHPy150Open sigmavirus24/github3.py/tests/integration/test_repos_repo.py/TestRepository.test_statuses