Sha256: 5945fb07fac815765dc6b2c5d91077035eb6aba0fea3960f53680bc1f5161d8b

Contents?: true

Size: 1.57 KB

Versions: 2

Compression:

Stored size: 1.57 KB

Contents

require 'lib/micronaut/rake_task'

begin 
  require 'jeweler' 
  Jeweler::Tasks.new do |s| 
    s.name = "micronaut" 
    s.executables = "micronaut" 
    s.summary = "An excellent replacement for the wheel..."
    s.email = "chad@spicycode.com" 
    s.homepage = "http://github.com/spicycode/micronaut" 
    s.description = "An excellent replacement for the wheel..."
    s.authors = ["Chad Humphries"] 
    s.files =  FileList["[A-Z]*", "{bin,lib,examples}/**/*"] 
  end 
rescue => e
  puts "Jeweler, or one of its dependencies blew right up. #{e}"
rescue LoadError 
  puts "Jeweler, or one of its dependencies, is not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com" 
end

desc "List files that don't have examples"
task :untested do
  code = Dir["lib/**/*.rb"].map { |g| Dir.glob(g) }.flatten
  examples = Dir["examples/**/*_example.rb"].map { |g| Dir.glob(g) }.flatten
  examples.map! { |f| f =~ /examples\/(.*)_example/; "#{$1}.rb" }
  puts "\nThe following files seem to be missing their examples:"
  (code - examples).each do |missing|
    puts "  #{missing}"
  end
end

desc "Run all micronaut examples"
Micronaut::RakeTask.new :examples do |t|
  t.pattern = "examples/**/*_example.rb"
end

namespace :examples do
  
  desc "Run all micronaut examples using rcov"
  Micronaut::RakeTask.new :coverage do |t|
    t.pattern = "examples/**/*_example.rb"
    t.rcov = true
    t.rcov_opts = %[--exclude "examples/*,gems/*,db/*,/Library/Ruby/*,config/*" --text-summary  --sort coverage --no-validator-links]
  end

end

task :default => 'examples:coverage'

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
spicycode-micronaut-0.2.5 Rakefile
spicycode-micronaut-0.2.7 Rakefile