Sha256: dcbd08ca02f005f3d508c8e77031842be45050b032a546a898114facb485a593

Contents?: true

Size: 599 Bytes

Versions: 9

Compression:

Stored size: 599 Bytes

Contents

require "bundler/gem_tasks"
require "rspec/core/rake_task"
require "open3"

RSpec::Core::RakeTask.new(:spec)

task default: :spec

desc 'This updates the migrations used by the testing Rails Dummy app and should be run whenever those are updated.'
task :update_test_schema do
  puts "Updating the test database and schema..."
  stream_command("cd spec/dummy; bundle exec rake db:drop; bundle exec rake db:create; bundle exec rake db:migrate")
end

def stream_command(cmd)
  Open3.popen2e(cmd) do |stdin, stdout_stderr, wait_thr|
    while line = stdout_stderr.gets
      puts line
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
inst_data_shipper-0.2.6 Rakefile
inst_data_shipper-0.2.5 Rakefile
inst_data_shipper-0.2.4 Rakefile
inst_data_shipper-0.2.3 Rakefile
inst_data_shipper-0.2.2 Rakefile
inst_data_shipper-0.2.1 Rakefile
inst_data_shipper-0.2.0 Rakefile
inst_data_shipper-0.1.0.beta2 Rakefile
inst_data_shipper-0.1.0.beta1 Rakefile