(t *testing.T)
| 146 | } |
| 147 | |
| 148 | func TestPRReady_alreadyReady(t *testing.T) { |
| 149 | http := &httpmock.Registry{} |
| 150 | defer http.Verify(t) |
| 151 | |
| 152 | shared.StubFinderForRunCommandStyleTests(t, "123", &api.PullRequest{ |
| 153 | ID: "THE-ID", |
| 154 | Number: 123, |
| 155 | State: "OPEN", |
| 156 | IsDraft: false, |
| 157 | }, ghrepo.New("OWNER", "REPO")) |
| 158 | |
| 159 | output, err := runCommand(http, true, "123") |
| 160 | assert.NoError(t, err) |
| 161 | assert.Equal(t, "", output.String()) |
| 162 | assert.Equal(t, "! Pull request OWNER/REPO#123 is already \"ready for review\"\n", output.Stderr()) |
| 163 | } |
| 164 | |
| 165 | func TestPRReadyUndo(t *testing.T) { |
| 166 | http := &httpmock.Registry{} |
nothing calls this directly
no test coverage detected