(
title: string,
head: string,
body: string = DEFAULT_PR_BODY,
)
| 677 | } |
| 678 | |
| 679 | async createPR( |
| 680 | title: string, |
| 681 | head: string, |
| 682 | body: string = DEFAULT_PR_BODY, |
| 683 | ): Promise<ForgejoPullRequest> { |
| 684 | return this.request(`${this.originRepoURL}/pulls`, { |
| 685 | method: 'POST', |
| 686 | body: JSON.stringify({ |
| 687 | title, |
| 688 | head: await this.getHeadReference(head), |
| 689 | base: this.branch, |
| 690 | body, |
| 691 | }), |
| 692 | }); |
| 693 | } |
| 694 | |
| 695 | async updatePR(number: number, state: 'open' | 'closed'): Promise<ForgejoPullRequest> { |
| 696 | return this.request(`${this.originRepoURL}/pulls/${number}`, { |
no test coverage detected