mirror of
https://github.com/go-gitea/gitea.git
synced 2026-05-14 13:08:11 +02:00
Fix test
This commit is contained in:
parent
94424b788d
commit
bad9ae0f58
@ -320,7 +320,7 @@ func TestAPICreateBranchWithSyncBranches(t *testing.T) {
|
|||||||
RepoID: 1,
|
RepoID: 1,
|
||||||
})
|
})
|
||||||
assert.NoError(t, err)
|
assert.NoError(t, err)
|
||||||
assert.Len(t, branches, 9)
|
assert.Len(t, branches, 10)
|
||||||
|
|
||||||
branches, err = db.Find[git_model.Branch](t.Context(), git_model.FindBranchOptions{
|
branches, err = db.Find[git_model.Branch](t.Context(), git_model.FindBranchOptions{
|
||||||
RepoID: 1,
|
RepoID: 1,
|
||||||
|
|||||||
@ -409,12 +409,6 @@ func TestCantMergeUnrelated(t *testing.T) {
|
|||||||
assert.NoError(t, err)
|
assert.NoError(t, err)
|
||||||
defer gitRepo1.Close()
|
defer gitRepo1.Close()
|
||||||
|
|
||||||
_, _, err = gitcmd.NewCommand("branch", "unrelated").
|
|
||||||
AddDynamicArguments(commitSha).
|
|
||||||
WithDir(path).
|
|
||||||
RunStdString(t.Context())
|
|
||||||
assert.NoError(t, err)
|
|
||||||
|
|
||||||
assert.NoError(t, repo_service.CreateNewBranchFromCommit(t.Context(), user1, repo1, gitRepo1, commitSha, "unrelated"))
|
assert.NoError(t, repo_service.CreateNewBranchFromCommit(t.Context(), user1, repo1, gitRepo1, commitSha, "unrelated"))
|
||||||
|
|
||||||
testEditFileToNewBranch(t, session, "user1", "repo1", "master", "conflict", "README.md", "Hello, World (Edited Once)\n")
|
testEditFileToNewBranch(t, session, "user1", "repo1", "master", "conflict", "README.md", "Hello, World (Edited Once)\n")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user