mirror of
https://github.com/go-gitea/gitea.git
synced 2026-02-05 06:47:12 +01:00
fix
This commit is contained in:
@@ -40,7 +40,7 @@ func (ut *RenderUtils) RenderTimelineEventComment(c *issues_model.Comment, creat
|
||||
if !isToggle {
|
||||
return locale.Tr("repo.issues.change_title_at", ut.RenderEmoji(c.OldTitle), ut.RenderEmoji(c.NewTitle), createdStr)
|
||||
}
|
||||
trKey := util.Iif(isWip, "repo.pulls.marked_as_work_in_progress", "repo.pulls.marked_as_ready_for_review")
|
||||
trKey := util.Iif(isWip, "repo.pulls.marked_as_work_in_progress_at", "repo.pulls.marked_as_ready_for_review_at")
|
||||
return locale.Tr(trKey, createdStr)
|
||||
}
|
||||
setting.PanicInDevOrTesting("unimplemented comment type %v: %v", c.Type, c)
|
||||
|
||||
@@ -21,10 +21,10 @@ func TestRenderTimelineEventComment(t *testing.T) {
|
||||
var createdStr template.HTML = "(created-at)"
|
||||
|
||||
c := &issues_model.Comment{Type: issues_model.CommentTypeChangeTitle, OldTitle: "WIP: title", NewTitle: "title"}
|
||||
assert.Equal(t, "repo.pulls.marked_as_ready_for_review:(created-at)", string(ut.RenderTimelineEventComment(c, createdStr)))
|
||||
assert.Equal(t, "repo.pulls.marked_as_ready_for_review_at:(created-at)", string(ut.RenderTimelineEventComment(c, createdStr)))
|
||||
|
||||
c = &issues_model.Comment{Type: issues_model.CommentTypeChangeTitle, OldTitle: "title", NewTitle: "WIP: title"}
|
||||
assert.Equal(t, "repo.pulls.marked_as_work_in_progress:(created-at)", string(ut.RenderTimelineEventComment(c, createdStr)))
|
||||
assert.Equal(t, "repo.pulls.marked_as_work_in_progress_at:(created-at)", string(ut.RenderTimelineEventComment(c, createdStr)))
|
||||
|
||||
c = &issues_model.Comment{Type: issues_model.CommentTypeChangeTitle, OldTitle: "title", NewTitle: "WIP: new title"}
|
||||
assert.Equal(t, "repo.issues.change_title_at:title,WIP: new title,(created-at)", string(ut.RenderTimelineEventComment(c, createdStr)))
|
||||
|
||||
@@ -1778,8 +1778,8 @@
|
||||
"repo.pulls.title_desc": "wants to merge %[1]d commits from <code>%[2]s</code> into <code id=\"branch_target\">%[3]s</code>",
|
||||
"repo.pulls.merged_title_desc": "merged %[1]d commits from <code>%[2]s</code> into <code>%[3]s</code> %[4]s",
|
||||
"repo.pulls.change_target_branch_at": "changed target branch from <b>%s</b> to <b>%s</b> %s",
|
||||
"repo.pulls.marked_as_work_in_progress": "marked the pull request as work in progress %s",
|
||||
"repo.pulls.marked_as_ready_for_review": "marked the pull request as ready for review %s",
|
||||
"repo.pulls.marked_as_work_in_progress_at": "marked the pull request as work in progress %s",
|
||||
"repo.pulls.marked_as_ready_for_review_at": "marked the pull request as ready for review %s",
|
||||
"repo.pulls.tab_conversation": "Conversation",
|
||||
"repo.pulls.tab_commits": "Commits",
|
||||
"repo.pulls.tab_files": "Files Changed",
|
||||
|
||||
Reference in New Issue
Block a user