Skip to content
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.

Commit

Permalink
Cleaned up Rakefile
Browse files Browse the repository at this point in the history
  • Loading branch information
Ondřej Musil committed May 2, 2016
1 parent cc6eb0b commit 2a4122b
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 21 deletions.
42 changes: 21 additions & 21 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,41 +1,41 @@
# encoding: utf-8
require "rubygems"
require "rspec/core/rake_task"

require 'rubygems'

require 'bundler/setup'
require 'bundler/gem_tasks'

require 'yard'
require 'cucumber'
require 'cucumber/rake/task'
begin
require 'bundler/gem_tasks'
rescue LoadError
puts "Cannot load bundler/gem_tasks"
end
require 'rspec/core/rake_task'

desc "Run all features"
desc 'Run all features'
Cucumber::Rake::Task.new(:features) do |t|
t.cucumber_opts = "features --format pretty"
t.cucumber_opts = 'features --format pretty'
end

desc "Run all specs"
desc 'Run all specs'
RSpec::Core::RakeTask.new(:spec) do |t|
t.fail_on_error = false
t.verbose = true
end

desc 'Default: Run all specs.'
task :default => :spec

task :test => :spec

task :doc => :yard
task :gem => :gemspec

def gemspec
@gemspec ||= eval(File.read('apiary.gemspec'), binding, '.gemspec')
end

YARD::Rake::YardocTask.new

desc "Validate the gemspec"
desc 'Validate the gemspec'
task :gemspec do
gemspec.validate
end

YARD::Rake::YardocTask.new

# Aliases
desc 'Default: Run all specs.'
task :default => :spec

task :test => :spec
task :doc => :yard
task :gem => :gemspec
1 change: 1 addition & 0 deletions spec/spec.opts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--color

0 comments on commit 2a4122b

Please sign in to comment.