mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-08-05 09:55:20 +02:00
ui for adding following repos
This commit is contained in:
parent
eea841d25d
commit
82cb9e0203
15 changed files with 284 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
|||
// Copyright 2017 The Gitea Authors. All rights reserved.
|
||||
// Copyright 2024 The Forgejo Authors. All rights reserved.
|
||||
// SPDX-License-Identifier: MIT
|
||||
|
||||
package repo_test
|
||||
|
@ -217,3 +218,12 @@ func TestComposeSSHCloneURL(t *testing.T) {
|
|||
setting.SSH.Port = 123
|
||||
assert.Equal(t, "ssh://git@[::1]:123/user/repo.git", repo_model.ComposeSSHCloneURL("user", "repo"))
|
||||
}
|
||||
|
||||
func TestAPActorID(t *testing.T) {
|
||||
repo := repo_model.Repository{ID: 1}
|
||||
url := repo.APActorID()
|
||||
expected := "https://try.gitea.io/api/v1/activitypub/repository-id/1"
|
||||
if url != expected {
|
||||
t.Errorf("unexpected APActorID, expected: %q, actual: %q", expected, url)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue