Rakefile in rs_232-2.3.2.pre vs Rakefile in rs_232-3.0.0.pre2

- old
+ new

@@ -1,13 +1,35 @@ lib = File.expand_path '../lib', __FILE__ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include? lib + require 'bundler/setup' require 'bundler/gem_tasks' -require 'rake' -load 'tasks/clean.rake' -load 'tasks/cov.rake' -load 'tasks/rspec.rake' -load 'tasks/cucumber.rake' -load 'tasks/compile.rake' +require 'rake/extensiontask' +Rake::ExtensionTask.new('rs_232') do |ext| + ext.name = 'rs_232_native' + ext.source_pattern = '*.{c,cpp}' +end -task default: [:clobber, :compile, :spec, :features] +require 'rake/clean' +CLEAN.include %w(**/*.{log} doc coverage tmp pkg **/*.{o,so,bundle} Makefile) + +require 'simplecov' +task :cov do + ENV['SIMPLECOV'] = 'features' + Rake::Task['default'].invoke +end + +require 'cucumber/rake/task' +Cucumber::Rake::Task.new(:features) do |t| + t.fork = true + t.profile = :default +end + +require 'rspec/core/rake_task' +RSpec::Core::RakeTask.new do |t| + t.fail_on_error = false + t.verbose = true + t.rspec_opts = '--format RspecJunitFormatter --out rspec.xml --tag ~wip' +end + +task default: [:clobber, :compile, :spec]