Skip to content

Commit

Permalink
fix(fossil): add ADDED_BY_MERGE to status
Browse files Browse the repository at this point in the history
resolves #5695
  • Loading branch information
JanDeDobbeleer committed Sep 30, 2024
1 parent 9f4bd8d commit 06df61a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/segments/fossil.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ func (s *FossilStatus) add(code string) {
switch code {
case "CONFLICT":
s.Conflicted++
case "DELETED":
case "DELETED", "MISSING":
s.Deleted++
case "ADDED", "ADDED_BY_INTEGRATE":
case "ADDED", "ADDED_BY_INTEGRATE", "ADDED_BY_MERGE":
s.Added++
case "EDITED", "UPDATED", "UPDATED_BY_INTEGRATE", "UPDATED_BY_MERGE", "CHANGED":
s.Modified++
Expand Down
4 changes: 3 additions & 1 deletion src/segments/fossil_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,10 @@ func TestFossilStatus(t *testing.T) {
comment: In the /setup_skin page, add a mention of/link to /skins, per request in the forum. (user: stephan)
CONFLICT test.tst
DELETED test.tst
MISSING test.tst
ADDED test.tst
ADDED_BY_INTEGRATE test.tst
ADDED_BY_MERGE test.tst
EDITED auto.def
UPDATED test.tst
UPDATED_BY_INTEGRATE test.tst
Expand All @@ -55,7 +57,7 @@ func TestFossilStatus(t *testing.T) {
RENAMED test.tst
`,
ExpectedBranch: "trunk",
ExpectedStatus: "+2 ~5 -1 >1 !1",
ExpectedStatus: "+3 ~5 -2 >1 !1",
},
}
for _, tc := range cases {
Expand Down

0 comments on commit 06df61a

Please sign in to comment.