-
Notifications
You must be signed in to change notification settings - Fork 59
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
Custom inspec resources not loaded: 'undefined method' #120
Comments
I'm running into this issue as well. Whenever I put a custom resource into I don't understand how to get it to load my files before In short, I'm stumped on this, and I feel like I'm going crazy. As far as I can tell, the official documentation is still in line with that article, so I'm not quite sure why it doesn't work. kitchen 1.14.2 |
It works for me using the following directory structure https://github.com/chef/kitchen-inspec#directory-structure-with-complete-profile |
I tried that but was getting errors of an invalid format:
Turns out I simply needed the inspec.yml file. I assumed since I didn't actually care to put any configuration in there I could just omit it, but I should have realized that's why it wasn't finding a supported structure. Thanks! |
Custom resources in profiles cannot be in the |
@adamleff what do you mean by move your class up one level? |
I'm trying to implement some kitchen-inspec tests using a custom inspec resource in the spirit of this blog post. Thus I have created a file named
test/integration/my-suite/libraries/query.rb
with the following content:My test case
test/integration/my-suite/default_spec.rb
isWhen running kitchen via
kitchen verify my-suite
the new resource doesn't seem to be available:I also tried putting the inspec resource definition directly in my test-case with the same result.
Thanks in advance!
The text was updated successfully, but these errors were encountered: