mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-23 04:39:28 +02:00
Update module github.com/golangci/golangci-lint/cmd/golangci-lint to v2 (forgejo) (#7367)
Co-authored-by: Renovate Bot <forgejo-renovate-action@forgejo.org> Co-committed-by: Renovate Bot <forgejo-renovate-action@forgejo.org>
This commit is contained in:
parent
51ff4970ec
commit
fed2d81c44
427 changed files with 2043 additions and 2046 deletions
|
@ -112,7 +112,7 @@ func TestAPILFSLocksLogged(t *testing.T) {
|
|||
var lfsLock api.LFSLockResponse
|
||||
DecodeJSON(t, resp, &lfsLock)
|
||||
assert.Equal(t, test.user.Name, lfsLock.Lock.Owner.Name)
|
||||
assert.EqualValues(t, lfsLock.Lock.LockedAt.Format(time.RFC3339), lfsLock.Lock.LockedAt.Format(time.RFC3339Nano)) // locked at should be rounded to second
|
||||
assert.Equal(t, lfsLock.Lock.LockedAt.Format(time.RFC3339), lfsLock.Lock.LockedAt.Format(time.RFC3339Nano)) // locked at should be rounded to second
|
||||
for _, id := range test.addTime {
|
||||
resultsTests[id].locksTimes = append(resultsTests[id].locksTimes, time.Now())
|
||||
}
|
||||
|
@ -129,9 +129,9 @@ func TestAPILFSLocksLogged(t *testing.T) {
|
|||
DecodeJSON(t, resp, &lfsLocks)
|
||||
assert.Len(t, lfsLocks.Locks, test.totalCount)
|
||||
for i, lock := range lfsLocks.Locks {
|
||||
assert.EqualValues(t, test.locksOwners[i].Name, lock.Owner.Name)
|
||||
assert.Equal(t, test.locksOwners[i].Name, lock.Owner.Name)
|
||||
assert.WithinDuration(t, test.locksTimes[i], lock.LockedAt, 10*time.Second)
|
||||
assert.EqualValues(t, lock.LockedAt.Format(time.RFC3339), lock.LockedAt.Format(time.RFC3339Nano)) // locked at should be rounded to second
|
||||
assert.Equal(t, lock.LockedAt.Format(time.RFC3339), lock.LockedAt.Format(time.RFC3339Nano)) // locked at should be rounded to second
|
||||
}
|
||||
|
||||
req = NewRequestWithJSON(t, "POST", fmt.Sprintf("/%s.git/info/lfs/locks/verify", test.repo.FullName()), map[string]string{})
|
||||
|
@ -143,7 +143,7 @@ func TestAPILFSLocksLogged(t *testing.T) {
|
|||
assert.Len(t, lfsLocksVerify.Ours, test.oursCount)
|
||||
assert.Len(t, lfsLocksVerify.Theirs, test.theirsCount)
|
||||
for _, lock := range lfsLocksVerify.Ours {
|
||||
assert.EqualValues(t, test.user.Name, lock.Owner.Name)
|
||||
assert.Equal(t, test.user.Name, lock.Owner.Name)
|
||||
deleteTests = append(deleteTests, struct {
|
||||
user *user_model.User
|
||||
repo *repo_model.Repository
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue