Sha256: 8c9af059af4698afb09e2b7d7ba435b0011699f93dde098aa970245c6f687354

Contents?: true

Size: 829 Bytes

Versions: 39

Compression:

Stored size: 829 Bytes

Contents

if defined? RSpec
	require 'rspec/core/rake_task'

	desc 'Run the code in spec'
	RSpec::Core::RakeTask.new(:spec) do |t|
		t.pattern = "spec/**/*_spec.rb"
	end

	namespace :spec do
		%w(core plugin acceptance).each do |dir|
			desc "Run the code examples in spec/#{dir}"
			RSpec::Core::RakeTask.new(dir.to_sym) do |t|
				t.pattern = "spec/#{dir}/**/*_spec.rb"
			end
		end

		namespace :acceptance do
			desc 'Run the code examples in spec/acceptance with cgi mode'
			task :cgi do
				ENV['TEST_MODE'] = 'webrick'
				Rake::Task["spec:acceptance"].invoke
			end
		end

		desc 'Displayed code coverage with SimpleCov'
		task :coverage do
			ENV['COVERAGE'] = 'simplecov'
			Rake::Task["spec"].invoke
		end
	end
end

# Local Variables:
# mode: ruby
# indent-tabs-mode: t
# tab-width: 3
# ruby-indent-level: 3
# End:
# vim: ts=3

Version data entries

39 entries across 29 versions & 1 rubygems

Version Path
tdiary-5.3.0 lib/tdiary/tasks/rspec.rake
tdiary-5.2.4 lib/tdiary/tasks/rspec.rake
tdiary-5.2.3 lib/tdiary/tasks/rspec.rake
tdiary-5.2.2 lib/tdiary/tasks/rspec.rake
tdiary-5.2.1 lib/tdiary/tasks/rspec.rake
tdiary-5.2.0 lib/tdiary/tasks/rspec.rake
tdiary-5.1.7 lib/tdiary/tasks/rspec.rake
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/3.0.0/gems/tdiary-5.1.4/lib/tdiary/tasks/rspec.rake
tdiary-5.1.6 lib/tdiary/tasks/rspec.rake
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/lib/tdiary/tasks/rspec.rake
tdiary-5.1.5 lib/tdiary/tasks/rspec.rake
tdiary-5.1.5 vendor/bundle/ruby/3.0.0/gems/tdiary-5.1.4/lib/tdiary/tasks/rspec.rake
tdiary-5.1.4 lib/tdiary/tasks/rspec.rake
tdiary-5.1.3 lib/tdiary/tasks/rspec.rake
tdiary-5.1.2 lib/tdiary/tasks/rspec.rake
tdiary-5.1.2 vendor/bundle/ruby/2.6.0/gems/tdiary-5.0.14/lib/tdiary/tasks/rspec.rake
tdiary-5.1.1 vendor/bundle/ruby/2.6.0/gems/tdiary-5.0.14/lib/tdiary/tasks/rspec.rake
tdiary-5.1.1 lib/tdiary/tasks/rspec.rake
tdiary-5.1.0 lib/tdiary/tasks/rspec.rake
tdiary-5.0.14 lib/tdiary/tasks/rspec.rake