def test_no_prs_included(self): """Runs through the process with a few PRs being available, but without including any of them.""" prs = [PullRequestFactory() for i in range(0, 3)] with self.activate_mocks(): self.get_open_prs_mock.return_value = prs self.ask_include_pr_mock.return_value = False make_release() self.assert_git_commands_ran([]) self.inspect_and_delete_csv([])
def test_all_prs_included(self): """Runs through the process with a few PRs being available, all of which are included.""" prs = [PullRequestFactory() for i in range(0, 3)] with self.activate_mocks(): self.get_open_prs_mock.return_value = prs make_release() self.assert_git_commands_ran(prs) self.inspect_and_delete_csv([ [str(pr.pr_id), str(pr.branch_name)] for pr in prs ])
#!/usr/bin/env python # -*- encoding: utf-8 -*- from __future__ import unicode_literals from releasemaker.cli_io import make_release if __name__ == '__main__': make_release()
def test_no_prs(self): """Runs through the whole process without any PRs being available.""" with self.activate_mocks(): make_release() self.assert_git_commands_ran([]) self.inspect_and_delete_csv([])