This repository was archived by the owner on Sep 30, 2024. It is now read-only.
Commit 68da82c 1 parent cee1f50 commit 68da82c Copy full SHA for 68da82c
File tree 2 files changed +14
-0
lines changed
2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -2942,6 +2942,15 @@ func TestListSourcegraphDotComIndexableRepos(t *testing.T) {
2942
2942
}
2943
2943
}
2944
2944
2945
+ func TestRepoNotFoundFulfillsNotFound (t * testing.T ) {
2946
+ err := & RepoNotFoundErr {
2947
+ ID : api .RepoID (1 ),
2948
+ Name : api .RepoName ("github.com/foo/bar" ),
2949
+ HashedName : api .RepoHashedName ("github.com/foo/bar" ),
2950
+ }
2951
+ require .True (t , errcode .IsNotFound (err ))
2952
+ }
2953
+
2945
2954
func TestRepoStore_Metadata (t * testing.T ) {
2946
2955
if testing .Short () {
2947
2956
t .Skip ()
Original file line number Diff line number Diff line change @@ -1400,6 +1400,11 @@ func TestUsers_CreateCancelAccessRequest(t *testing.T) {
1400
1400
assert .Equal (t , updated .Status , types .AccessRequestStatusCanceled )
1401
1401
}
1402
1402
1403
+ func TestUserNotFoundFulfillsNotFound (t * testing.T ) {
1404
+ err := NewUserNotFoundError (123 )
1405
+ require .True (t , errcode .IsNotFound (err ))
1406
+ }
1407
+
1403
1408
func normalizeUsers (users []* types.User ) []* types.User {
1404
1409
for _ , u := range users {
1405
1410
u .CreatedAt = u .CreatedAt .Local ().Round (time .Second )
You can’t perform that action at this time.
0 commit comments