Sha256: 0facf9ddf560c81cb2ae7d83463c0719ad4b13f646464476764ac1b6e9598954

Contents?: true

Size: 341 Bytes

Versions: 18

Compression:

Stored size: 341 Bytes

Contents

module Bait
  module SpecHelpers
    module ScriptMaker
      def write_script_with_status script, status
        File.open(script, "w") do |f|
          f.puts "#!/usr/bin/env bash"
          f.puts "echo this is a test script"
          f.puts "exit #{status.to_i}"
        end
        File.chmod(0755, script)
      end
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
bait-0.5.13 spec/support/script_maker.rb
bait-0.5.12 spec/support/script_maker.rb
bait-0.5.11 spec/support/script_maker.rb
bait-0.5.10 spec/support/script_maker.rb
bait-0.5.9 spec/support/script_maker.rb
bait-0.5.6 spec/support/script_maker.rb
bait-0.5.5 spec/support/script_maker.rb
bait-0.5.4 spec/support/script_maker.rb
bait-0.5.2 spec/support/script_maker.rb
bait-0.5.1 spec/support/script_maker.rb
bait-0.5.0 spec/support/script_maker.rb
bait-0.4.1 spec/support/script_maker.rb
bait-0.4.0 spec/support/script_maker.rb
bait-0.3.2 spec/support/script_maker.rb
bait-0.3.1 spec/support/script_maker.rb
bait-0.3.0 spec/support/script_maker.rb
bait-0.2.1 spec/support/script_maker.rb
bait-0.2.0 spec/support/script_maker.rb