Sha256: e5215754d9569a0172f7434efef1586118d86be90db44c2fce8df5724b79bae9

Contents?: true

Size: 1.03 KB

Versions: 3

Compression:

Stored size: 1.03 KB

Contents

require 'bundler/gem_tasks'
require 'rake/testtask'
require 'rdoc/task'

desc 'Run unit tests'
Rake::TestTask.new(:test => 'test:rebuild_database') do |t|
  t.libs << "#{File.dirname(__FILE__)}/lib"
  t.pattern = "#{File.dirname(__FILE__)}/test/*_test.rb"
  t.verbose = true
end

task :default => :test

desc 'Generate documentation'
Rake::RDocTask.new(:rdoc) do |rdoc|
  rdoc.rdoc_dir = 'html'
  rdoc.title    = 'Class Table Inheritance for Rails'
  rdoc.options << '--line-numbers' << '--inline-source'
  rdoc.template = ENV['template'] ? "#{ENV['template']}.rb" : './doc/template/horo'
  rdoc.rdoc_files.include('README.rdoc')
  rdoc.rdoc_files.include('./lib/**/*.rb')
end

namespace :test do
  desc 'Build the test database'
  task :create_database do
    %x( createdb -U postgres updateable_views_inheritance_test )
  end

  desc 'Drop the test database'
  task :drop_database do 
    %x( dropdb  -U postgres updateable_views_inheritance_test )
  end

  desc 'Rebuild the test database'
  task :rebuild_database => [:drop_database, :create_database]
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
updateable_views_inheritance-1.2.1 Rakefile
updateable_views_inheritance-1.2.0 Rakefile
updateable_views_inheritance-1.1.2 Rakefile