Skip to content

Commit

Permalink
Merge pull request #134 from schubergphilis/master
Browse files Browse the repository at this point in the history
Ignore files under the `test/` directory
  • Loading branch information
svanharmelen committed Sep 1, 2023
2 parents 19ba13f + 16a1bd7 commit 329015a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
Chef-Guard CHANGELOG
====================

0.7.4
------------------
- Ignore files under the `test/` directory

0.7.3
------------------
- Switch to using Go modules, but still vendor (`go mod vendor`) for backwards compatibility
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.7.3
0.7.4
2 changes: 1 addition & 1 deletion validations.go
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ func (cg *ChefGuard) searchSourceCookbook() (errCode int, err error) {

func (cg *ChefGuard) ignoreThisFile(file string, ignoreDefaultFiles bool) (ignore bool, err error) {
if ignoreDefaultFiles {
if file == "metadata.rb" || file == "metadata.json" || strings.HasPrefix(file, "spec/") {
if file == "metadata.rb" || file == "metadata.json" || strings.HasPrefix(file, "spec/") || strings.HasPrefix(file, "test/") {
return true, nil
}
}
Expand Down

0 comments on commit 329015a

Please sign in to comment.