Sha256: 8813dc179b978880651f23529f712abe8e4df69a3cb3d50b2e20a7b2b8d00e8a

Contents?: true

Size: 825 Bytes

Versions: 12

Compression:

Stored size: 825 Bytes

Contents

Given /^I am at the project root$/ do
  expect(Dir.pwd.split('/').last).to eq("flapjack")
end

Then /^I should see (\d+) lines of output$/ do |number|
  expect(@output.split.size).to eq(number.to_i)
end

Then /^every file in the output should start with "([^\"]*)"$/ do |string|
  @output.split.each do |file|
    expect(`head -n 1 #{file}`).to match(/^#{string}\s*$/)
  end
end

When /^I run `([^"]*)`$/ do |cmd|
  @cmd = cmd
  @output = `#{cmd} 2>&1`
  @exit_status = $?.exitstatus
  puts "output: #{@output}" if @debug
  puts "exit_status: #{@exit_status}" if @debug
end

Then /^the exit status should( not)? be (\d+)$/ do |negativity, number|
  expect(@exit_status).send(negativity ? :not_to : :to, eq(number.to_i))
end

Then /^the output should contain "([^"]*)"$/ do |matcher|
  expect(@output).to include(matcher)
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
flapjack-0.8.11 features/steps/packaging-lintian_steps.rb
flapjack-0.8.10 features/steps/packaging-lintian_steps.rb
flapjack-0.8.9 features/steps/packaging-lintian_steps.rb
flapjack-0.8.8 features/steps/packaging-lintian_steps.rb
flapjack-0.8.7 features/steps/packaging-lintian_steps.rb
flapjack-0.8.6 features/steps/packaging-lintian_steps.rb
flapjack-0.8.5 features/steps/packaging-lintian_steps.rb
flapjack-0.8.4 features/steps/packaging-lintian_steps.rb
flapjack-0.8.3 features/steps/packaging-lintian_steps.rb
flapjack-0.8.2 features/steps/packaging-lintian_steps.rb
flapjack-0.8.1 features/steps/packaging-lintian_steps.rb
flapjack-0.8.0 features/steps/packaging-lintian_steps.rb