forked from kevadesu/forgejo
Enable mocked HTTP responses for GitLab migration test
This commit is contained in:
parent
52053b1389
commit
19cefc4de2
22 changed files with 595 additions and 1 deletions
|
@ -27,7 +27,7 @@ func TestGitlabDownloadRepo(t *testing.T) {
|
|||
// If no access token is available, those cached responses will be used instead.
|
||||
gitlabPersonalAccessToken := os.Getenv("GITLAB_READ_TOKEN")
|
||||
fixturePath := "./testdata/gitlab/full_download"
|
||||
server := unittest.NewMockWebServer(t, "https://gitlab.com", fixturePath, true)
|
||||
server := unittest.NewMockWebServer(t, "https://gitlab.com", fixturePath, gitlabPersonalAccessToken != "")
|
||||
defer server.Close()
|
||||
|
||||
downloader, err := NewGitlabDownloader(context.Background(), server.URL, "gitea/test_repo", "", "", gitlabPersonalAccessToken)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue