mirror of
https://github.com/inspec/inspec
synced 2024-11-27 07:00:39 +00:00
62dc14a09c
* Fix `only_if` behavior when used outside controls This renames `@skip_profile` to `@skip_file` and modifies the scope of `only_if` (used outside of a control) to only apply to the control file that contains it instead of the entire profile. This does this by exposing `@skip_file` from the control context so that it can be set back to `false` between loading control files in the profile context. Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com> * Modify `get_checks` to accept a rule index Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com> * Modify `only_if` to work regardless of location Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com> * Disable Cyclomatic/Perceived Complexity in Rubocop Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com> * Add comment for `skip_file` in `load_control_file` Signed-off-by: Jerry Aldrich <jerryaldrichiii@gmail.com> |
||
---|---|---|
.. | ||
control_eval_context_test.rb | ||
library_eval_context_test.rb | ||
metadata_test.rb | ||
profile_context_test.rb | ||
profile_test.rb |