Sha256: b6ae9d448855af1b7caae04c3f07cd73c56416bf425bbe0bea6c295cc22d9a34

Contents?: true

Size: 1.86 KB

Versions: 8

Compression:

Stored size: 1.86 KB

Contents

@announce @work_in_cwd @cookbooks @cookbook_metadata
Feature: Cookbook Metadata
  In order to understand cookbooks without evaluating them
  As an Administrator
  I want to automatically generate metadata about cookbooks

  Background:
    Given a default base Chef repository in "ckbk/scratch/myapp"
      And the local Chef repository exists
      And the file "ckbk/scratch/myapp/.chef/knife.rb" contains:
      """
      current_dir = File.dirname(__FILE__)
      log_level :debug
      log_location $stdout
      node_name "bobo"
      client_key "#{File.dirname(current_dir)}/bobo.pem"
      chef_server_url "http://localhost:4000"
      cache_type 'Memory'
      cache_options( :path => "#{ENV['HOME']}/.chef/checksums" )
      cookbook_path ["#{current_dir}/../cookbooks","#{current_dir}/../site-cookbooks"]

      """
      And Explanation: Next we step up two levels to escape Aruba's working folder
      And the remote Cookbook repository "./../../features/data/repositories/cookbooks/hosts/.git"
      And I clone the remote Cookbook repository branch "master" to "ckbk/scratch/myapp/cookbooks/hosts"
      And the local Cookbook repository exists

  Scenario: Generate metadata for all cookbooks
     When I successfully generate all Cookbook metadata
      And the output contains "DEBUG: Generated "
      And the output does not contain "DEBUG: No "
    Then the file "ckbk/scratch/myapp/cookbooks/hosts/metadata.json" exists

  Scenario: Generate metadata for a specific cookbook
     When we record the a-mtime of "ckbk/scratch/myapp/cookbooks/hosts/metadata.json"
      And I successfully generate Cookbook "hosts" metadata
      And the output contains "DEBUG: Generated "
      And the output does not contain "DEBUG: No "
    Then the file "ckbk/scratch/myapp/cookbooks/hosts/metadata.json" exists
      And the mtime of "ckbk/scratch/myapp/cookbooks/hosts/metadata.json" changes

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
cuken-0.1.22 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.21 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.20 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.19 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.18 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.17 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.16 features/chef_examples/cookbooks_metadata.feature
cuken-0.1.15 features/chef_examples/cookbooks_metadata.feature