-
Notifications
You must be signed in to change notification settings - Fork 170
Chef generate cookbook creates tests in a different location than where kitchen-inspec looks for tests #964
Comments
Edit: Initially I closed this ticket, based on a false reading. After talking with @ricardolupo I've revised the description and initial report. Thanks Lupo! |
The challenge here is that Test case:
|
Updated the title and description of this issue to be more descriptive. Thanks for reporting this, @ricardolupo! |
add trailing 15:19:42-rlupo~/cookbooks/dev/foo (master)$ kitchen verify Target: ssh://[email protected]:32778 |
Another side effect is #1027 which causes foodcritic to fail. I think it makes the most sense for |
Now the generator explicitly generates an |
Issue Description
The default cookbook generators in chef-dk do not create the necessary scaffolding to work with
kitchen-inspec
.By default,
kitchen-inspec
looks for tests in the cookbooks in these locations, in order of preference:./test/recipes/default/
./test/integration/default/inspec/
However,
chef generate cookbook
lays down tests in/test/recipes/
, without thedefault
subdirectory.Current behavior
In order to run Inspec tests, people must either:
kitchen-inspec
;.kitchen.yml
file to point to the default created tests in./test/recipes/default_test.rb
Desired Behavior
ChefDK Version
Chef Development Kit Version: 0.16.28
Platform Version
Mac OS/X latest
Replication Case
chef generate cookbook foo
cd foo
delivery local smoke
mkdir test/recipes/default && mv test/recipes/default_test.rb test/recipes/default/default_test.rb
delivery local smoke
The text was updated successfully, but these errors were encountered: