Exemplo n.º 1
0
    def create_issue_comment(self, HEAD, target_pr):
        parser, sub_parser = parsers()
        command = UnrebasedPRs(sub_parser)
        o, e = self.sandbox.communicate(
            "git", "log", "--oneline", "-n", "1", HEAD)
        sha1, num, rest = command.parse_pr(o.split("\n")[0])

        pr = PullRequest(self.sandbox.origin.get_pull(num))
        comment = pr.create_issue_comment("--rebased-from #%s" % target_pr)
        return comment
Exemplo n.º 2
0
 def runCheck(self):
     self.assertEqual(UnrebasedPRs.check_directed_links(self.d1, self.d2),
                      self.m2)
     self.assertEqual(UnrebasedPRs.check_directed_links(self.d2, self.d1),
                      self.m1)