-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
style(inspec): match current practices for file and control names #212
style(inspec): match current practices for file and control names #212
Conversation
13c1d13
to
1001fe4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At work, we also use Inspec like it was/is (except for the filename which has no real sense in fact) before this PR. Do other changes comes from Inspec own documentation?
I don't really found guidelines to write |
Looks fine, but I'm not sure there is any 'standard', first file opened https://github.com/inspec/inspec/blob/master/examples/kitchen-chef/test/integration/default/web_spec.rb :) with a title and control which forms a complete sentence. |
Thanks for going to this effort, @baby-gnu. Nice to see working group items getting tackled. I'm pretty happy with the changes, unless we can find some official guidelines for how to make these adjustments. By the way, this also reminded me that we have this user story in Taiga, to propose adding some |
You're right @daks and then I found things like this and the counter example in the same directory 🤪 |
As the one who brought this up in the WG, here is what my comments were based on: Chef InSpec Profile Style Guide |
1001fe4
to
adb80d0
Compare
adb80d0
to
56c4b4a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps I'm being pedantic but just making some suggestions for tidiness/consistency.
56c4b4a
to
728640c
Compare
I don't find a reference best practices in the documentation but as stated during a SaltStack Formula Workgroup meeting: - the `_spec` in the control file name is inherited from RSpec and few examples use it - the `control` name should be an identifier, I matched the `tpldot` name - the `title` is a human readable description of the `control` - remove `impact` which is not appropriate for an integration test
728640c
to
aa8a58b
Compare
🎉 This PR is included in version 4.3.7 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
* saltstack-formulas/template-formula#212 Use `:r! grep -riIn _mapdata_spec` to locate all of the lines to be adjusted. Then fix with `%s:_mapdata_spec.rb:_mapdata.rb:` (check changes carefully afterwards). Use `:r! find ssf/files/ -name _mapdata_spec.rb` to locate all of the templates to rename and adjust.
* saltstack-formulas/template-formula#212 Use `:r! grep -riIn _mapdata_spec` to locate all of the lines to be adjusted. Then fix with `%s:_mapdata_spec.rb:_mapdata.rb:` (check changes carefully afterwards). Use `:r! find ssf/files/ -name _mapdata_spec.rb` to locate all of the templates to rename and adjust.
Changes have been propagated to all formulas using myii/ssf-formula#292. |
Note, this means that |
PR progress checklist (to be filled in by reviewers)
What type of PR is this?
Primary type
[build]
Changes related to the build system[chore]
Changes to the build process or auxiliary tools and libraries such as documentation generation[ci]
Changes to the continuous integration configuration[feat]
A new feature[fix]
A bug fix[perf]
A code change that improves performance[refactor]
A code change that neither fixes a bug nor adds a feature[revert]
A change used to revert a previous commit[style]
Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.)Secondary type
[docs]
Documentation changes[test]
Adding missing or correcting existing testsDoes this PR introduce a
BREAKING CHANGE
?No.
Related issues and/or pull requests
Describe the changes you're proposing
I don't find a reference best practices in the documentation but:
the
_spec
in the control file name is inherited from RSpec and few examples use itthe
control
name should be an identifier, I matched thetpldot
namethe
title
is a human readable description of thecontrol
Pillar / config required to test the proposed changes
Debug log showing how the proposed changes work
Now the output looks like this:
Documentation checklist
README
(e.g.Available states
).pillar.example
.Testing checklist
state_top
).Additional context
We spoke abouth this in Salt Formula Working Group 2020-09-08