summaryrefslogtreecommitdiff
path: root/spec/data
Commit message (Collapse)AuthorAgeFilesLines
...
* CHEF-4203: Honor the chefignore file for knife cookbook testMatt Veitas2014-03-284-0/+14
| | | | In the case that a standalone cookbook exists that is using bundler, a large amount of gems can be added to the current directory. This commit reads the chefignore file and avoid having to scan through the ruby files that are in the bundler created gems directory.
* CHEF-4849: Implement `#response_file_variables` in Package resourcePeter Fern2013-12-201-0/+1
| | | | | | | | Now that Chef properly supports a package `response_file` using `Chef::Resource::Template`, the Package resource should implement the `response_file_variables` method so that variables do not have to exist as node attributes (eg - for seeding DB passwords for configuration files generated by packages).
* Add a directory where trusted certs can be storeddanielsdeleo2013-10-174-0/+109
|
* [CHEF-3609] Test no_proxy entries during bootstrapSean Horn2013-10-101-0/+2
|
* Prevent duplicate keys in cookbook version JSONSeth Falcon2013-10-101-0/+8
| | | | | | | | | | | | | | | | Reported in CHEF-4571. The recipes component of cookbook version metadata (cbv.metadata.recipes) serialized to JSON with duplicate keys if a metadata.rb was present that provided a recipe line matching the cookbook name (providing a description for the default recipe). The root cause is the behavior of the JSON serialized when called on a hash containing matching string and symbol keys. For example: chef > {"key1" => "sam", :key1 => "wat"}.to_json => "{\"key1\":\"sam\",\"key1\":\"wat\"}" So the specific fix is to prevent inserting a symbol key for the recipe name.
* revert whitespace for all spec/data fixturesLamont Granquist2013-09-2642-53/+53
| | | | | | - some of these have deliberate whitespace/line-ending differences - without going through them one by one its safer to revert the lot of them
* undo whitespace changeLamont Granquist2013-09-261-1/+1
|
* Reset some_windows_line_endings test fixtureSeth Vargo2013-09-261-1/+2
|
* Normalize whitespace on all filesSeth Vargo2013-09-2644-56/+55
|
* Verify that templates are preferred to files for preseedingdanielsdeleo2013-08-021-0/+4
|
* Fix bad const. ref in deprecation/provider/templatedanielsdeleo2013-08-021-1/+1
| | | | | | | | | | | | | | Fixes CHEF-4406 http://tickets.opscode.com/browse/CHEF-4406 Calls to Chef::Provider::Template#template_location and #template_finder will now correctly reference the Chef::Provider::TemplateFinder class. Chef::Provider::Package#preseed_resource uses these methods expecting an error to be raised only if there is no template with the desired name, which triggers a fallback to cookbook_file-based preseed files. This patch restores the template-based preseed functionality, but will trigger deprecation warnings from within Chef::Provider::Package's internal code.
* Add functional tests for (apt) package resourcedanielsdeleo2013-08-0238-0/+246
| | | | Repro/regression test for CHEF-4406 included but is marked pending.
* Revert "Merge branch 'CHEF-3307'"Bryan McLellan2013-07-034-4/+0
| | | | | | | | This reverts commit 5713a002062c762e40e4378be6d7763eb3dd61a2, reversing changes made to 4079a344f2001c1927132e7ed6b63453f459609f. Conflicts: spec/unit/cookbook_loader_spec.rb
* CHEF-3544 Honor chefignore in cookbook syntax checkGreg Thornton2013-06-182-0/+3
|
* don't depend on line separator in partial testsdanielsdeleo2013-06-141-1/+1
| | | | | | | | | | | In some windows testing environments no line separator conversion is happening. This may be a function of git settings, or something else in our test cluster environment. In any case, line separators are irrelevant to these tests, as they are testing the partial template feature. We could remove the line endings from the test fixture files, but editors like vim add hidden newlines at the end of files, so this is difficult to maintain. Stripping the line endings within the test code is more sustainable option.
* Prevent integration tests from loading real configdanielsdeleo2013-06-101-0/+1
| | | | | | | | | | knife integration tests were picking up default config and therefore pointing at a chef-server other than the chef-zero test instance. This could potentially lead to data loss or manglement if the test code successfully runs against a production chef-server/org. To prevent the above, load a dummy config file with an added failsafe mechanism to ensure we've not loaded a real one.
* Merge branch 'master' into file-refactorsersut2013-05-315-0/+4
|\ | | | | | | | | Conflicts: lib/chef/exceptions.rb
| * [CHEF-2420] Support annotated tags in the git providerSeth Falcon2013-05-241-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Annotated tags have their own SHA and also point to a SHA in the git repo. Using git ls-remote $REPO $TAG* the tagged SHAs can be identified by the '^{}' suffix appended to the corresponding tag name. When resolving the remote reference, we now search for $TAG* and use the SHA of the tagged commit (with ^{}) if it is there and otherwise use the SHA with an exact match for $TAG (to avoid capturing anything extra via the glob used to return refs). If no revision is specified, we force 'HEAD' in the git ls-remote call to constrain what can come back from the remote. Further, we protect against a badly chosen annotated tag named 'HEAD'. The functional test suite includes a git bundle of a small example repo. We found that locally cloning this bundle provided the closest simulation of `git ls-remote` behavior. YMMV depending on git version. The test suite could be extended to improve overall coverage, but does verify the desired behavior for annotated tags.
| * Tests CHEF-3307Mal Graty2013-05-244-0/+4
| | | | | | | | | | | | | | | | | | Test cookbook loading, shadowing and metadata deprecation warnings assocaited with the CHEF-3307 changes (use of metadata name as cookbook name in preference to file system pathname). Includes new nginx cookbook (with alternate pathname) and a shadowbook with another pathname.
* | Merge pull request #795 from opscode/ss/binmode-fixesSerdar Sutay2013-05-313-0/+12
|\ \ | | | | | | Binmode and Template line endings
| * | Make sure that windows line endings are protected during template rendering.sersut2013-05-303-0/+12
| | |
* | | only test class-specific methods for compatibilitydanielsdeleo2013-05-311-1/+127
|/ / | | | | | | | | | | Generated a new method list for checking interface compatibility, removing inherited methods. This makes the test more stable across ruby versions since methods on Object may change from 1.8->1.9->2.0.
* | Pass template extensions through to partialsdanielsdeleo2013-05-291-0/+1
| | | | | | | | | | | | | | - move the new TemplateContext code into mixin/template and consolidate with ChefContext - Copy extension modules from parent template to partial template. - Functional tests for helpers with partials.
* | Add helper method/module support to template resourcedanielsdeleo2013-05-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds helper methods to a template via the following syntax: ``` template "name" do # singular method definition: helper(:method_name) { method_body } # inline module definition helpers do def method_name method_body end end # external module inclusion helpers(MyHelperModule) end ``` In each of the above cases, variables defined by Chef (e.g., `@node`) or the user (via `:variables => {}`) can be accessed as normal. Could use the following improvements: - Template partials are not supported - Input validation on Resource::Template should be improved - Needs Unit tests for Template provider/implementation classes
* | Spec for deprecation.sersut2013-05-161-0/+1
| |
* | Merge branch 'master' into file-refactorsersut2013-05-144-0/+18
|\ \ | |/ | | | | | | | | Conflicts: spec/unit/knife/configure_spec.rb spec/unit/provider/remote_file_spec.rb
| * [CHEF-4117] fix resource attempting to remove constants it doesn't havedanielsdeleo2013-04-231-0/+0
| | | | | | | | | | | | Module.const_defined?() needs to be given an optional second argument to disable constant lookups on ancestor classes. Otherwise LWRP creation may attempt to remove a constant that does not exist.
| * [CHEF-4011] `--secret` and `--secret-file` options for `knife bootstrap`Seth Chisamore2013-04-112-0/+10
| | | | | | | | | | | | | | | | | | This commit adds new CLI options to `knife bootstrap` for specifying encrypted data bag secret key (actual string or file) at node bootstrap time. This approach is more explicit than the previous approach of reading the path to the secret key from the `encrypted_data_bag_secret` value in the knife.rb file. For backward compatibility we will still attempt to load a key from Chef::Config[:encrypted_data_bag_secret].
| * [CHEF-3932] Add unit tests for Knife's lazy dependency loadingTeemu Matilainen2013-04-111-0/+8
| |
| * Revert "Merge branch 'CHEF-1031'"Bryan McLellan2013-03-011-0/+0
|/ | | | | | | | This reverts commit a82935b4a8e1e8174d02e83259f07ea9926dd007, reversing changes made to 464087c7a6da4ed51237cbb6ff39e45feeae0ecd. Conflicts: lib/chef/provider/remote_file/ftp.rb
* functional test for CHEF-3140Jesse Campbell2013-02-261-0/+0
|
* CHEF-1292 Lower json stack depth tests to 301Bryan McLellan2013-02-122-2/+4
| | | | | 1001 was causing stack level too deep errors on 1.8.7. This is still a huge stack depth and 1001 was arbitrary.
* remove even more ohai plugins from chef-shell testdanielsdeleo2013-01-221-0/+1
|
* ignore some solaris ohai plugins in chef-shell testsdanielsdeleo2013-01-211-0/+2
|
* Merge branch '10-stable' into integrate-chef-10-18-0danielsdeleo2013-01-171-0/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .gitattributes chef-expander/Rakefile chef-expander/lib/chef/expander/version.rb chef-server-api/Rakefile chef-server-api/chef-server-api.gemspec chef-server-api/lib/chef-server-api/version.rb chef-server-webui/Rakefile chef-server-webui/chef-server-webui.gemspec chef-server-webui/lib/chef-server-webui/version.rb chef-server/Rakefile chef-server/lib/chef-server/version.rb chef-solr/lib/chef/solr/version.rb chef.gemspec chef/Rakefile chef/spec/support/platform_helpers.rb chef/spec/support/shared/functional/file_resource.rb chef/spec/unit/api_client_spec.rb chef/spec/unit/provider/directory_spec.rb ci/jenkins_run_tests.bat ci/jenkins_run_tests.sh distro/common/html/chef-client.8.html distro/common/html/chef-expander.8.html distro/common/html/chef-expanderctl.8.html distro/common/html/chef-server-webui.8.html distro/common/html/chef-server.8.html distro/common/html/chef-shell.1.html distro/common/html/chef-solo.8.html distro/common/html/chef-solr.8.html distro/common/html/knife-bootstrap.1.html distro/common/html/knife-client.1.html distro/common/html/knife-configure.1.html distro/common/html/knife-cookbook-site.1.html distro/common/html/knife-cookbook.1.html distro/common/html/knife-data-bag.1.html distro/common/html/knife-environment.1.html distro/common/html/knife-exec.1.html distro/common/html/knife-index.1.html distro/common/html/knife-node.1.html distro/common/html/knife-role.1.html distro/common/html/knife-search.1.html distro/common/html/knife-ssh.1.html distro/common/html/knife-status.1.html distro/common/html/knife-tag.1.html distro/common/html/knife.1.html distro/common/man/man1/chef-shell.1 distro/common/man/man1/knife-bootstrap.1 distro/common/man/man1/knife-client.1 distro/common/man/man1/knife-configure.1 distro/common/man/man1/knife-cookbook-site.1 distro/common/man/man1/knife-cookbook.1 distro/common/man/man1/knife-data-bag.1 distro/common/man/man1/knife-environment.1 distro/common/man/man1/knife-exec.1 distro/common/man/man1/knife-index.1 distro/common/man/man1/knife-node.1 distro/common/man/man1/knife-role.1 distro/common/man/man1/knife-search.1 distro/common/man/man1/knife-ssh.1 distro/common/man/man1/knife-status.1 distro/common/man/man1/knife-tag.1 distro/common/man/man1/knife.1 distro/common/man/man8/chef-client.8 distro/common/man/man8/chef-expander.8 distro/common/man/man8/chef-expanderctl.8 distro/common/man/man8/chef-server-webui.8 distro/common/man/man8/chef-server.8 distro/common/man/man8/chef-solo.8 distro/common/man/man8/chef-solr.8 lib/chef/api_client.rb lib/chef/rest.rb lib/chef/version.rb spec/functional/knife/ssh_spec.rb spec/functional/resource/cookbook_file_spec.rb spec/spec_helper.rb spec/stress/win32/security_spec.rb spec/support/shared/functional/securable_resource.rb spec/unit/config_spec.rb spec/unit/knife/ssh_spec.rb
| * move test files from cherry-pick to correct part of treedanielsdeleo2012-11-052-0/+0
| |
| * Merge branch 'OC-4668'danielsdeleo2012-11-052-0/+0
| |
* | [CHEF-3681] Test LWPs with inline compilationdanielsdeleo2012-12-271-0/+26
| |
* | [CHEF-3249] Fix nested partials; add a test for that.Andrea Campi2012-12-141-0/+1
| |
* | CHEF-3660: rename files that didn't play nice with git rebasesdelano2012-12-131-0/+0
| |
* | [CHEF-3376] Update fixture cookbooks for run_context testsdanielsdeleo2012-11-3039-0/+61
| |
* | disable ohai plugins for shell func testsdanielsdeleo2012-11-211-0/+7
| |
* | [CHEF-2903] load attribute files in run_list orderdanielsdeleo2012-11-0722-0/+9
| |
* | [OC-4668] add functional tests for deploy_revisiondanielsdeleo2012-11-052-0/+0
| |
* | [OC-3564] move core Chef to the repo root \o/ \m/Seth Chisamore2012-10-30122-0/+674
|/ | | | The opscode/chef repository now only contains the core Chef library code used by chef-client, knife and chef-solo!
* big refactor of the repo layout. move to a chef gem and a chef-server gem ↵Ezra Zygmuntowicz2008-10-0830-170/+0
| | | | all with proper deps
* Adding specs for new resource types, fixes to node, mixin::templateAdam Jacob2008-09-081-0/+1
|
* Adding test recipeAdam Jacob2008-04-081-0/+5
|
* removing left over debug output in compile_specAdam Jacob2008-04-081-1/+1
|
* Adding chef-solo command, config examples, Chef::Log class, ↵Adam Jacob2008-04-0812-4/+74
| | | | Chef::Log::Formatter, Chef::Compile, and all the tests