Skip to content

Commit

Permalink
Detect pyup as an automated dependency update tool (#2226)
Browse files Browse the repository at this point in the history
Signed-off-by: Jeremy Katz <jeremy@tidelift.com>

Signed-off-by: Jeremy Katz <jeremy@tidelift.com>
  • Loading branch information
katzj authored Sep 1, 2022
1 parent d13ba3f commit f345807
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
13 changes: 13 additions & 0 deletions checks/raw/dependency_update_tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,19 @@ var checkDependencyFileExists fileparser.DoWhileTrueOnFilename = func(name strin
},
},
})
case ".pyup.yml":
*ptools = append(*ptools, checker.Tool{
Name: "PyUp",
URL: asPointer("https://pyup.io/"),
Desc: asPointer("Automated dependency updates for Python."),
Files: []checker.File{
{
Path: name,
Type: checker.FileTypeSource,
Offset: checker.OffsetDefault,
},
},
})
default:
// Continue iterating.
return true, nil
Expand Down
9 changes: 9 additions & 0 deletions checks/raw/dependency_update_tool_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,15 @@ func Test_checkDependencyFileExists(t *testing.T) {
want: false,
wantErr: false,
},
{
name: ".pyup.yml",
args: args{
name: ".pyup.yml",
data: &[]checker.Tool{},
},
want: false,
wantErr: false,
},
}
for _, tt := range tests {
tt := tt
Expand Down

0 comments on commit f345807

Please sign in to comment.