mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Enable testifylint rules (#34075)
enable testifylint rules disabled in: https://github.com/go-gitea/gitea/pull/34054
This commit is contained in:
@@ -84,7 +84,7 @@ func TestMigrateGiteaForm(t *testing.T) {
|
||||
assert.True(t, exists, "The template has changed")
|
||||
serviceInput, exists := form.Find(`input[name="service"]`).Attr("value")
|
||||
assert.True(t, exists)
|
||||
assert.EqualValues(t, fmt.Sprintf("%d", structs.GiteaService), serviceInput)
|
||||
assert.Equal(t, fmt.Sprintf("%d", structs.GiteaService), serviceInput)
|
||||
// Step 4: submit the migration to only migrate issues
|
||||
migratedRepoName := "otherrepo"
|
||||
req = NewRequestWithValues(t, "POST", link, map[string]string{
|
||||
@@ -100,7 +100,7 @@ func TestMigrateGiteaForm(t *testing.T) {
|
||||
resp = session.MakeRequest(t, req, http.StatusSeeOther)
|
||||
// Step 5: a redirection displays the migrated repository
|
||||
loc := resp.Header().Get("Location")
|
||||
assert.EqualValues(t, fmt.Sprintf("/%s/%s", ownerName, migratedRepoName), loc)
|
||||
assert.Equal(t, fmt.Sprintf("/%s/%s", ownerName, migratedRepoName), loc)
|
||||
// Step 6: check the repo was created
|
||||
unittest.AssertExistsAndLoadBean(t, &repo_model.Repository{Name: migratedRepoName})
|
||||
})
|
||||
|
Reference in New Issue
Block a user