diff options
author | sdelano <stephen@opscode.com> | 2010-11-23 10:07:08 -0800 |
---|---|---|
committer | Tim Hinderliter <tim@opscode.com> | 2011-03-17 16:56:43 -0700 |
commit | 1c398d98f08f03cfe609b1c58233a6727ef92a28 (patch) | |
tree | cefe5baa21b9d2a610a1dc62c627a3b2bcdae7e8 /features | |
parent | 300e2d9b5aad97287e2d1750cdadfc9555441741 (diff) | |
download | chef-1c398d98f08f03cfe609b1c58233a6727ef92a28.tar.gz |
simple case for cookbook dependency feature tests
Diffstat (limited to 'features')
30 files changed, 518 insertions, 0 deletions
diff --git a/features/api/nodes/cookbook_sync_api.feature b/features/api/nodes/cookbook_sync_api.feature index ecbf57444c..6f74ab946d 100644 --- a/features/api/nodes/cookbook_sync_api.feature +++ b/features/api/nodes/cookbook_sync_api.feature @@ -59,3 +59,14 @@ Feature: Synchronize cookbooks to the edge When I 'GET' the path '/nodes/sync/cookbooks' Then I should get a '403 "Forbidden"' exception + @cookbook_dependencies + Scenario: Retrieve the list of cookbook files to sync + Given I am an administrator + And I upload the set of 'dep_test_*' cookbooks + And a 'node' named 'empty' exists + And changing the 'node' field 'run_list' to 'recipe[dep_test_a@1.0.0]' + When I 'PUT' the 'node' to the path 'nodes/empty' + And I 'GET' the path 'nodes/empty/cookbooks' + Then cookbook 'dep_test_a' should have version '1.0.0' + Then cookbook 'dep_test_b' should have version '1.0.0' + Then cookbook 'dep_test_c' should have version '1.0.0' diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/metadata.json new file mode 100644 index 0000000000..5c2dab5366 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/metadata.json @@ -0,0 +1,31 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + "dep_test_b": "< 2.0.0", + "dep_test_c": "< 2.0.0" + }, + "version": "1.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_a", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/metadata.rb new file mode 100644 index 0000000000..667c04b9bd --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/metadata.rb @@ -0,0 +1,8 @@ +name "dep_test_a" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "1.0.0" +depends "dep_test_b", "< 2.0.0" +depends "dep_test_c", "< 2.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_1.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/metadata.json new file mode 100644 index 0000000000..62eba94b04 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/metadata.json @@ -0,0 +1,29 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + }, + "version": "2.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_a", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/metadata.rb new file mode 100644 index 0000000000..78d8b0b9c6 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/metadata.rb @@ -0,0 +1,6 @@ +name "dep_test_a" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "2.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_2.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/metadata.json new file mode 100644 index 0000000000..d362bdeac2 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/metadata.json @@ -0,0 +1,29 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + }, + "version": "3.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_a", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/metadata.rb new file mode 100644 index 0000000000..23a7478ce6 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/metadata.rb @@ -0,0 +1,6 @@ +name "dep_test_a" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "3.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_a_3.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/metadata.json new file mode 100644 index 0000000000..4bccc932c4 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/metadata.json @@ -0,0 +1,31 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + "dep_test_a": "< 2.0.0", + "dep_test_c": "< 2.0.0" + }, + "version": "1.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_b", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/metadata.rb new file mode 100644 index 0000000000..a4a4fd2c5e --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/metadata.rb @@ -0,0 +1,8 @@ +name "dep_test_b" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "1.0.0" +depends "dep_test_a", "< 2.0.0" +depends "dep_test_c", "< 2.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_1.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/metadata.json new file mode 100644 index 0000000000..447c59c27e --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/metadata.json @@ -0,0 +1,29 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + }, + "version": "2.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_b", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/metadata.rb new file mode 100644 index 0000000000..ef66810667 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/metadata.rb @@ -0,0 +1,6 @@ +name "dep_test_b" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "2.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_2.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/metadata.json new file mode 100644 index 0000000000..9ad609451f --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/metadata.json @@ -0,0 +1,29 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + }, + "version": "3.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_b", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/metadata.rb new file mode 100644 index 0000000000..e65e598afd --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/metadata.rb @@ -0,0 +1,6 @@ +name "dep_test_b" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "3.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_b_3.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/metadata.json new file mode 100644 index 0000000000..b2377a1a20 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/metadata.json @@ -0,0 +1,31 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + "dep_test_a": "< 2.0.0", + "dep_test_b": "< 2.0.0" + }, + "version": "1.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_c", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/metadata.rb new file mode 100644 index 0000000000..1c71ed4432 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/metadata.rb @@ -0,0 +1,8 @@ +name "dep_test_c" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "1.0.0" +depends "dep_test_a", "< 2.0.0" +depends "dep_test_b", "< 2.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_1.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/metadata.json new file mode 100644 index 0000000000..f3b924b03a --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/metadata.json @@ -0,0 +1,29 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + }, + "version": "2.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_c", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/metadata.rb new file mode 100644 index 0000000000..03c581e895 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/metadata.rb @@ -0,0 +1,6 @@ +name "dep_test_c" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "2.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_2.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/metadata.json b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/metadata.json new file mode 100644 index 0000000000..954c5cff03 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/metadata.json @@ -0,0 +1,29 @@ +{ + "recommendations": { + }, + "description": "Tests cookbook versioning in environments", + "suggestions": { + }, + "attributes": { + }, + "platforms": { + }, + "long_description": "", + "conflicting": { + }, + "dependencies": { + }, + "version": "3.0.0", + "providing": { + }, + "maintainer": "Opscode", + "recipes": { + }, + "replacing": { + }, + "license": "Apache 2.0", + "name": "dep_test_c", + "maintainer_email": "do_not_reply@opscode.com", + "groupings": { + } +}
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/metadata.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/metadata.rb new file mode 100644 index 0000000000..838753b7a4 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/metadata.rb @@ -0,0 +1,6 @@ +name "dep_test_c" +maintainer "Opscode" +maintainer_email "do_not_reply@opscode.com" +license "Apache 2.0" +description "Tests cookbook versioning in environments" +version "3.0.0"
\ No newline at end of file diff --git a/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/recipes/default.rb b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/recipes/default.rb new file mode 100644 index 0000000000..dc2a253959 --- /dev/null +++ b/features/data/cookbooks_not_uploaded_at_feature_start/dep_test_c_3.0.0/recipes/default.rb @@ -0,0 +1,18 @@ +# +# Cookbook Name:: template +# Recipe:: default +# +# Copyright 2010, Opscode, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# diff --git a/features/steps/cookbook_steps.rb b/features/steps/cookbook_steps.rb index e55def0094..7675bd416b 100644 --- a/features/steps/cookbook_steps.rb +++ b/features/steps/cookbook_steps.rb @@ -391,3 +391,16 @@ Given "I upload multiple versions of the 'version_test' cookbook that do not lex When "I fully upload a sandboxed cookbook force-named 'version_test' versioned '0.10.0' with 'version_test_0.10.0'" When "I fully upload a sandboxed cookbook force-named 'version_test' versioned '0.9.7' with 'version_test_0.9.7'" end + +Given "I upload the set of 'dep_test_*' cookbooks" do + %w{a b c}.each do |letter| + %w{1 2 3}.each do |number| + When "I fully upload a sandboxed cookbook force-named 'dep_test_#{letter}' versioned '#{number}.0.0' with 'dep_test_#{letter}_#{number}.0.0'" + end + end +end + +Then /^cookbook '(.+)' should have version '(.+)'$/ do |cookbook, version| + Then "the inflated responses key '#{cookbook}' should exist" + Then "the inflated responses key 'dep_test_a' should match '\"version\":\"#{version}\"' as json" +end diff --git a/features/steps/fixture_steps.rb b/features/steps/fixture_steps.rb index 368c388df1..4e339948c7 100644 --- a/features/steps/fixture_steps.rb +++ b/features/steps/fixture_steps.rb @@ -258,6 +258,11 @@ Before do n.deep_array = array n.deep_hash = hash n + end, + 'empty' => Proc.new do + n = Chef::Node.new + n.name 'empty' + n end }, 'hash' => { |