@@ -112,6 +112,7 @@ func TestAPILFSLocksLogged(t *testing.T) {
112112 if len (test .addTime ) > 0 {
113113 var lfsLock api.LFSLockResponse
114114 DecodeJSON (t , resp , & lfsLock )
115+ assert .Equal (t , test .user .Name , lfsLock .Lock .Owner .Name )
115116 assert .EqualValues (t , lfsLock .Lock .LockedAt .Format (time .RFC3339 ), lfsLock .Lock .LockedAt .Format (time .RFC3339Nano )) // locked at should be rounded to second
116117 for _ , id := range test .addTime {
117118 resultsTests [id ].locksTimes = append (resultsTests [id ].locksTimes , time .Now ())
@@ -129,7 +130,7 @@ func TestAPILFSLocksLogged(t *testing.T) {
129130 DecodeJSON (t , resp , & lfsLocks )
130131 assert .Len (t , lfsLocks .Locks , test .totalCount )
131132 for i , lock := range lfsLocks .Locks {
132- assert .EqualValues (t , test .locksOwners [i ].DisplayName () , lock .Owner .Name )
133+ assert .EqualValues (t , test .locksOwners [i ].Name , lock .Owner .Name )
133134 assert .WithinDuration (t , test .locksTimes [i ], lock .LockedAt , 10 * time .Second )
134135 assert .EqualValues (t , lock .LockedAt .Format (time .RFC3339 ), lock .LockedAt .Format (time .RFC3339Nano )) // locked at should be rounded to second
135136 }
@@ -143,7 +144,7 @@ func TestAPILFSLocksLogged(t *testing.T) {
143144 assert .Len (t , lfsLocksVerify .Ours , test .oursCount )
144145 assert .Len (t , lfsLocksVerify .Theirs , test .theirsCount )
145146 for _ , lock := range lfsLocksVerify .Ours {
146- assert .EqualValues (t , test .user .DisplayName () , lock .Owner .Name )
147+ assert .EqualValues (t , test .user .Name , lock .Owner .Name )
147148 deleteTests = append (deleteTests , struct {
148149 user * user_model.User
149150 repo * repo_model.Repository
@@ -165,7 +166,7 @@ func TestAPILFSLocksLogged(t *testing.T) {
165166 var lfsLockRep api.LFSLockResponse
166167 DecodeJSON (t , resp , & lfsLockRep )
167168 assert .Equal (t , test .lockID , lfsLockRep .Lock .ID )
168- assert .Equal (t , test .user .DisplayName () , lfsLockRep .Lock .Owner .Name )
169+ assert .Equal (t , test .user .Name , lfsLockRep .Lock .Owner .Name )
169170 }
170171
171172 // check that we don't have any lock
0 commit comments