Skip to content
This repository was archived by the owner on Dec 24, 2021. It is now read-only.

Commit a24b450

Browse files
Bumps version v2.0.2 -> v2.0.3
- Allow references to imported external InSpec profiles
1 parent e75e9ca commit a24b450

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,13 @@
33
We follow [Semantic Versioning](http://semver.org/) as a way of measuring stability of an update. This
44
means we will never make a backwards-incompatible change within a major version of the project.
55

6+
## v2.0.3 (2018-09-20)
7+
8+
- [BUG] InSpec tests that contain `require_controls` to import from other profiles should not be a linting error
9+
610
## v2.0.2 (2018-09-17)
711

8-
- Adds missing dependencies to gemspec for berkshelf and chef (dependency management)
12+
- [BUG] Adds missing dependencies to gemspec for berkshelf and chef (dependency management)
913
- [BUG] `rake dependency:update` leaves dependencies in wrapper cookbook on older than latest allowable version, per constraints defined in `Berksfile`
1014
- [BUG] `berks` commands seem unresponsive due to no output to STDOUT
1115

lib/rordan_gramsay/lint/test_checker.rb

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ def tests?
3232
def controls?
3333
@controls ||= @lines.any? { |line| line =~ /^.*(?<!#).*control[\s\(].*$/ }
3434
end
35+
36+
def external?
37+
@external ||= @lines.any? { |line| line =~ /^.*(?<!#).*(?:include|require)_controls[\s\(].*$/ }
38+
end
3539
end
3640

3741
def initialize
@@ -46,7 +50,7 @@ def call
4650
@files.each do |file|
4751
errors = []
4852
# errors << :missing_encoding_line unless file.encoding?
49-
errors << :missing_tests unless file.tests?
53+
errors << :missing_tests unless file.tests? || file.external?
5054

5155
# compile the error message
5256
if errors.empty?

lib/rordan_gramsay/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
module RordanGramsay
2-
VERSION = '2.0.2'.freeze
2+
VERSION = '2.0.3'.freeze
33
EXECUTABLE = 'gramsay'.freeze
44
GEM_NAME = 'rordan_gramsay'.freeze
55
end

0 commit comments

Comments
 (0)