~ubuntu-branches/ubuntu/karmic/chef/karmic

« back to all changes in this revision

Viewing changes to features/steps/packages.rb

  • Committer: Bazaar Package Importer
  • Author(s): Joshua Timberman
  • Date: 2009-08-12 12:18:48 UTC
  • Revision ID: james.westby@ubuntu.com-20090812121848-yl38hpd7nfsl51xz
Tags: upstream-0.7.8
ImportĀ upstreamĀ versionĀ 0.7.8

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Given /^that I have the (.+) package system installed$/ do |package_system|
 
2
  unless package_system_available?(package_system)
 
3
    pending "This Cucumber feature will not execute, as it is missing the #{package_system} packaging system."
 
4
  end
 
5
end
 
6
 
 
7
Then /^there should be a binary on the path called '(.+)'$/ do |binary_name|
 
8
  binary_name.strip!
 
9
  result = `which #{binary_name}`
 
10
  result.should_not =~ /not found/
 
11
end
 
12
 
 
13
Then /^there should not be a binary on the path called '(.+)'$/ do |binary_name|
 
14
  binary_name.strip!
 
15
  result = `which #{binary_name}`.strip
 
16
 
 
17
  unless result.empty?
 
18
    result.should =~ /not found/
 
19
  end
 
20
end