(t *testing.T)
| 42 | } |
| 43 | |
| 44 | func Test_List_perRepository(t *testing.T) { |
| 45 | reg := &httpmock.Registry{} |
| 46 | defer reg.Verify(t) |
| 47 | |
| 48 | reg.Register( |
| 49 | httpmock.REST("GET", "repos/OWNER/REPO/actions/artifacts"), |
| 50 | httpmock.StringResponse(`{}`)) |
| 51 | |
| 52 | api := &apiPlatform{ |
| 53 | client: &http.Client{Transport: reg}, |
| 54 | repo: ghrepo.New("OWNER", "REPO"), |
| 55 | } |
| 56 | _, err := api.List("") |
| 57 | require.NoError(t, err) |
| 58 | } |
| 59 | |
| 60 | func Test_Download(t *testing.T) { |
| 61 | tmpDir := t.TempDir() |