features/init_command.feature in berkshelf-2.0.18 vs features/init_command.feature in berkshelf-3.0.0.beta1
- old
+ new
@@ -3,11 +3,11 @@
I want a way to quickly prepare a Cookbook on my local disk with Berkshelf files
So that I can resolve my Cookbook's dependencies with Berkshelf
Scenario: initializing a path containing a cookbook
Given a cookbook named "sparkle_motion"
- When I run the init command with the cookbook "sparkle_motion" as the target
+ When I successfully run `berks init sparkle_motion`
Then the cookbook "sparkle_motion" should have the following files:
| Berksfile |
| chefignore |
And the file "Berksfile" in the cookbook "sparkle_motion" should contain:
"""
@@ -16,11 +16,11 @@
And the output should contain "Successfully initialized"
And the exit status should be 0
Scenario: initializing a path that does not contain a cookbook
Given a directory named "not_a_cookbook"
- When I run the init command with the directory "not_a_cookbook" as the target
+ When I successfully run `berks init not_a_cookbook`
Then the directory "not_a_cookbook" should have the following files:
| Berksfile |
And the directory "not_a_cookbook" should not have the following files:
| chefignore |
And the file "Berksfile" in the directory "not_a_cookbook" should not contain:
@@ -29,12 +29,10 @@
"""
And the output should contain "Successfully initialized"
And the exit status should be 0
Scenario: initializing with no value given for target
- When I run the init command with no value for the target
+ When I successfully run `berks init`
Then the output should contain "Successfully initialized"
- And the current directory should have the following files:
- | Berksfile |
- And the current directory should not have the following files:
- | chefignore |
+ And a file named "Berksfile" should exist
+ And a file named "chefignore" should not exist
And the exit status should be 0