We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a06bed4 commit 8e9e019Copy full SHA for 8e9e019
models/release_test.go
@@ -9,6 +9,7 @@ import (
9
10
"code.gitea.io/git"
11
12
+ "github.com/Unknwon/com"
13
"github.com/stretchr/testify/assert"
14
)
15
@@ -17,10 +18,13 @@ func TestRelease_Create(t *testing.T) {
17
18
19
user := AssertExistsAndLoadBean(t, &User{ID: 2}).(*User)
20
repo := AssertExistsAndLoadBean(t, &Repository{ID: 1}).(*Repository)
- repoPath := RepoPath(user.Name, repo.Name)
21
+
22
+ repoPath := repo.LocalCopyPath()
23
+ assert.True(t, com.IsExist(repoPath))
24
25
gitRepo, err := git.OpenRepository(repoPath)
26
assert.NoError(t, err)
27
+ assert.NotNil(t, gitRepo)
28
29
assert.NoError(t, CreateRelease(gitRepo, &Release{
30
RepoID: repo.ID,
0 commit comments