Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

RSS

minitest-handler (29) Versions 0.0.3

Installs and configures minitest-chef-handler

Berkshelf/Librarian
Policyfile
Knife
cookbook 'minitest-handler', '= 0.0.3'
cookbook 'minitest-handler', '= 0.0.3', :supermarket
knife cookbook site install minitest-handler
knife cookbook site download minitest-handler
README
Dependencies
Quality

Description

This cookbook utilizes the minitest-chef-handler project to facilitate cookbook testing.

minitest-chef-handler project: https://github.com/calavera/minitest-chef-handler
stable minitest-handler cookbook: http://community.opscode.com/cookbook/minitest-handler
minitest-handler cookbook development: https://github.com/btm/minitest-handler-cookbook

Requirements

The Opscode 'chef_handler' cookbook to allow the handler to be dynamically installed without modifying the client configuration

Attributes

node[:minitest][:path] - Location to store and find tests

Usage

  • The node run list should begin with 'recipe[chef_handler], recipe[chef-minitest]'
  • Each cookbook should contain tests in the 'files/default/tests/minitest' directory with a file suffix of '_test.rb'

Minitest: https://github.com/seattlerb/minitest

Example

class TestApache2 < MiniTest::Chef::TestCase
  def test_that_the_package_installed
    case node[:platform]
    when "ubuntu","debian"
      assert system('apt-cache policy apache2 | grep Installed | grep -v none')
    end
  end

  def test_that_the_service_is_running
    assert system('/etc/init.d/apache2 status')
  end

  def test_that_the_service_is_enabled
    assert File.exists?(Dir.glob("/etc/rc5.d/S*apache2").first)
  end
end

No quality metric results found