From f84291dcfdf724463069e678bef9fbd79d8b7147 Mon Sep 17 00:00:00 2001 From: Behnaz Hassanshahi Date: Fri, 4 Feb 2022 09:53:32 +1000 Subject: [PATCH] :bug: Fix Dependabot check to accept .yaml file extension (#1601) --- checks/raw/dependency_update_tool.go | 2 +- checks/raw/dependency_update_tool_test.go | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/checks/raw/dependency_update_tool.go b/checks/raw/dependency_update_tool.go index acb4b2916a4..ba653d32717 100644 --- a/checks/raw/dependency_update_tool.go +++ b/checks/raw/dependency_update_tool.go @@ -43,7 +43,7 @@ func checkDependencyFileExists(name string, data fileparser.FileCbData) (bool, e } switch strings.ToLower(name) { - case ".github/dependabot.yml": + case ".github/dependabot.yml", ".github/dependabot.yaml": *ptools = append(*ptools, checker.Tool{ Name: "Dependabot", URL: "https://github.com/dependabot", diff --git a/checks/raw/dependency_update_tool_test.go b/checks/raw/dependency_update_tool_test.go index a6fa8650f09..0e023495bdf 100644 --- a/checks/raw/dependency_update_tool_test.go +++ b/checks/raw/dependency_update_tool_test.go @@ -144,6 +144,14 @@ func TestDependencyUpdateTool(t *testing.T) { ".github/dependabot.yml", }, }, + { + name: "dependency update tool", + wantErr: false, + want: 1, + files: []string{ + ".github/dependabot.yaml", + }, + }, { name: "foo bar", wantErr: false,