Skip to content

Commit

Permalink
fixed tests data structure
Browse files Browse the repository at this point in the history
  • Loading branch information
orto17 committed Dec 11, 2024
1 parent 65af5fa commit 48d1dbe
Show file tree
Hide file tree
Showing 9 changed files with 4 additions and 47 deletions.
2 changes: 1 addition & 1 deletion packagehandlers/conanpackagehandler.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func (conan *ConanPackageHandler) UpdateDependency(vulnDetails *utils.Vulnerabil
func (conan *ConanPackageHandler) updateDirectDependency(vulnDetails *utils.VulnerabilityDetails) (err error) {
conanDescriptors, err := conan.CommonPackageHandler.GetAllDescriptorFilesFullPaths([]string{conanFileTxt, conanFilePy})
if err != nil {
err = fmt.Errorf("failed while serching for conanfile in project: %s", err.Error())
err = fmt.Errorf("failed while searching for Conan descriptor files in project: %s", err.Error())
return
}
isAnyDescriptorFileChanged := false
Expand Down
6 changes: 3 additions & 3 deletions packagehandlers/packagehandlers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ func TestUpdateDependency(t *testing.T) {
},
scanDetails: scanDetails,
fixSupported: true,
testDirName: filepath.Join("conan", "conan_txt"),
testDirName: filepath.Join("conan"),

Check failure on line 358 in packagehandlers/packagehandlers_test.go

View workflow job for this annotation

GitHub Actions / Static-Check

badCall: suspicious Join on 1 argument (gocritic)
descriptorsToCheck: []string{"conanfile.txt"},
},
{
Expand All @@ -366,7 +366,7 @@ func TestUpdateDependency(t *testing.T) {
},
scanDetails: scanDetails,
fixSupported: true,
testDirName: filepath.Join("conan", "conan_py"),
testDirName: filepath.Join("conan"),

Check failure on line 369 in packagehandlers/packagehandlers_test.go

View workflow job for this annotation

GitHub Actions / Static-Check

badCall: suspicious Join on 1 argument (gocritic)
descriptorsToCheck: []string{"conanfile.py"},
},
{
Expand All @@ -377,7 +377,7 @@ func TestUpdateDependency(t *testing.T) {
},
scanDetails: scanDetails,
fixSupported: true,
testDirName: filepath.Join("conan", "conan_py_txt"),
testDirName: filepath.Join("conan"),

Check failure on line 380 in packagehandlers/packagehandlers_test.go

View workflow job for this annotation

GitHub Actions / Static-Check

badCall: suspicious Join on 1 argument (gocritic)
descriptorsToCheck: []string{"conanfile.py", "conanfile.txt"},
},
},
Expand Down
23 changes: 0 additions & 23 deletions testdata/projects/conan/conan_py_txt/conanfile.py

This file was deleted.

8 changes: 0 additions & 8 deletions testdata/projects/conan/conan_py_txt/profile

This file was deleted.

4 changes: 0 additions & 4 deletions testdata/projects/conan/conan_txt/conanfile.txt

This file was deleted.

8 changes: 0 additions & 8 deletions testdata/projects/conan/conan_txt/profile

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 48d1dbe

Please sign in to comment.