File tree 1 file changed +5
-4
lines changed
1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change 9
9
10
10
"code.gitea.io/gitea/models"
11
11
"code.gitea.io/gitea/modules/test"
12
+ "code.gitea.io/gitea/services/gitdiff"
12
13
13
14
"github.com/stretchr/testify/assert"
14
15
)
@@ -25,10 +26,10 @@ func TestGetDiffPreview(t *testing.T) {
25
26
treePath := "README.md"
26
27
content := "# repo1\n \n Description for repo1\n this is a new line"
27
28
28
- expectedDiff := & models .Diff {
29
+ expectedDiff := & gitdiff .Diff {
29
30
TotalAddition : 2 ,
30
31
TotalDeletion : 1 ,
31
- Files : []* models .DiffFile {
32
+ Files : []* gitdiff .DiffFile {
32
33
{
33
34
Name : "README.md" ,
34
35
OldName : "README.md" ,
@@ -42,10 +43,10 @@ func TestGetDiffPreview(t *testing.T) {
42
43
IsLFSFile : false ,
43
44
IsRenamed : false ,
44
45
IsSubmodule : false ,
45
- Sections : []* models .DiffSection {
46
+ Sections : []* gitdiff .DiffSection {
46
47
{
47
48
Name : "" ,
48
- Lines : []* models .DiffLine {
49
+ Lines : []* gitdiff .DiffLine {
49
50
{
50
51
LeftIdx : 0 ,
51
52
RightIdx : 0 ,
You can’t perform that action at this time.
0 commit comments