Skip to content

Commit a58db69

Browse files
Thom MayNuo Yan
authored andcommitted
add features to test a versioned run list
1 parent 20f66c5 commit a58db69

1 file changed

Lines changed: 35 additions & 0 deletions

File tree

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
@api @nodes @api_nodes
2+
3+
Feature: Versioned Run List
4+
In order to maintain multiple versions of a cookbook
5+
As a DevOps
6+
I want to create and use multiple versions of a cookbook
7+
8+
Scenario: Unversioned run_list entries should automatically get the latest version
9+
Given I am an administrator
10+
And a validated node
11+
And it includes the recipe 'versions'
12+
When I run the chef-client
13+
Then the run should exit '0'
14+
And a file named 'thundercats_are_go.txt' should contain '1'
15+
16+
Scenario: Uploading a newer version of a cookbook should cause it to be used
17+
Given I am an administrator
18+
And a validated node
19+
And it includes the recipe 'versions'
20+
When I fully upload a sandboxed cookbook named 'versions' versioned '0.2.0' with 'versions'
21+
When I run the chef-client
22+
Then the run should exit '0'
23+
And a file named 'thundercats_are_go.txt' should contain '2'
24+
25+
Scenario: Providing a version number should cause that version of a cookbook to be used
26+
Given I am an administrator
27+
And a validated node
28+
And it includes the recipe 'versions' at version '0.1.0'
29+
When I fully upload a sandboxed cookbook named 'versions' versioned '0.2.0' with 'versions'
30+
When I run the chef-client
31+
Then the run should exit '0'
32+
And a file named 'thundercats_are_go.txt' should contain '1'
33+
34+
35+

0 commit comments

Comments
 (0)