lib/generators/cucumber/templates/Rakefile in singem-0.0.7 vs lib/generators/cucumber/templates/Rakefile in singem-0.1.0

- old
+ new

@@ -16,11 +16,11 @@ Spec::Rake::SpecTask.new do |t| t.spec_files = FileList['spec/**/*_spec.rb'] t.spec_opts = %w(-fs --color) t.spec_opts << '--loadby' << 'random' - t.rcov_opts << '--exclude' << 'spec' + t.rcov_opts << '--exclude' << 'spec,.bundle' t.rcov = ENV.has_key?('NO_RCOV') ? ENV['NO_RCOV'] != 'true' : true t.rcov_opts << '--text-summary' t.rcov_opts << '--sort' << 'coverage' << '--sort-reverse' end @@ -41,13 +41,13 @@ s.description = s.summary s.author = AUTHOR s.email = EMAIL s.homepage = HOMEPAGE - bundle = Bundler::Bundle.load(File.dirname(__FILE__) + '/Gemfile') - bundle.environment.dependencies.each do |dep| - next unless dep.only && dep.only.include?('runtime') - s.add_dependency(dep.name, dep.version.to_s) + bundle = Bundler::Definition.from_gemfile('Gemfile') + bundle.dependencies.each do |dep| + next unless dep.groups.include?(:runtime) + s.add_dependency(dep.name, dep.version_requirements.to_s) end s.require_path = 'lib' s.files = %w(LICENSE README.md Rakefile TODO) + Dir.glob("{lib,features}/**/*") end