Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100755 59 lines (46 sloc) 1.835 kb
1c202c5 @jcf Make Rakefile executable
jcf authored
1 #!/usr/bin/env rake
2
d73224f @jcf Rip out jeweler and use bundler instead
jcf authored
3 require 'bundler'
4 Bundler::GemHelper.install_tasks
bb63e1f Imported project to github
Bartosz Blimke authored
5
9948087 @jcf Rename spec:rubies task to rvm:specs
jcf authored
6 namespace :rvm do
221e8cd @jcf Document setting up a WebMock development environment
jcf authored
7 desc 'Run specs against 1.8.6, REE, 1.8.7, 1.9.2 and jRuby'
9948087 @jcf Rename spec:rubies task to rvm:specs
jcf authored
8 task :specs do
221e8cd @jcf Document setting up a WebMock development environment
jcf authored
9 # JCF: I'd love to be able to use RVM's `rvm {rubies} specs` command but
10 # the require tests in spec/other_net_http_libs_spec.rb break when doing
11 # so.
12 spec_files = Dir[File.dirname(__FILE__) + '/spec/**/*_spec.rb'].join(' ')
13 sh "rvm 1.8.6@webmock,ree@webmock,1.8.7@webmock,1.9.2@webmock,jruby@webmock exec rspec #{spec_files}"
14 end
15 end
16
e4a3b6b @bblimke Changed WebMock specs to use RSpec2
authored
17 require "rspec/core/rake_task"
af4c054 @bblimke Fixed Net::HTTP adapter to not break normal Net::HTTP behaviour when net...
authored
18 RSpec::Core::RakeTask.new(:spec) do |t|
d73224f @jcf Rip out jeweler and use bundler instead
jcf authored
19 t.rspec_opts = ["-c", "-f progress", "-r ./spec/spec_helper.rb"]
e4a3b6b @bblimke Changed WebMock specs to use RSpec2
authored
20 t.pattern = 'spec/**/*_spec.rb'
bb63e1f Imported project to github
Bartosz Blimke authored
21 end
22
af4c054 @bblimke Fixed Net::HTTP adapter to not break normal Net::HTTP behaviour when net...
authored
23 RSpec::Core::RakeTask.new(:spec_http_without_webmock) do |t|
9eea97b @bblimke Fixed spec paths in Rakewfile
authored
24 t.rspec_opts = ["-c", "-f progress", "-r ./spec/acceptance/net_http/real_net_http_spec.rb"]
25 t.pattern = 'spec/acceptance/net_http/real_net_http_spec.rb'
af4c054 @bblimke Fixed Net::HTTP adapter to not break normal Net::HTTP behaviour when net...
authored
26 end
27
fcea4b9 @bblimke Run WebMock specs against both EM-HTTP-Request 0.3 and EM-HTTP-Request 1...
authored
28
29 task :em_http_request_1_x_spec do
9eea97b @bblimke Fixed spec paths in Rakewfile
authored
30 sh "EM_HTTP_REQUEST_1_X=true bundle install && bundle exec rspec spec/acceptance/em_http_request/em_http_request_spec.rb" if RUBY_VERSION >= "1.9.2"
fcea4b9 @bblimke Run WebMock specs against both EM-HTTP-Request 0.3 and EM-HTTP-Request 1...
authored
31 end
32
bb63e1f Imported project to github
Bartosz Blimke authored
33 require 'rake/testtask'
34 Rake::TestTask.new(:test) do |test|
35 test.test_files = FileList["test/**/*.rb"].exclude("test/test_helper.rb")
36 test.verbose = false
2bd65d9 Upgraded gem version to 0.7.2
Bartosz Blimke authored
37 test.warning = false
bb63e1f Imported project to github
Bartosz Blimke authored
38 end
39
4710449 @bblimke Created separate folder with minitest tests instead of running them from...
authored
40 Rake::TestTask.new(:minitest) do |test|
41 test.test_files = FileList["minitest/**/*.rb"].exclude("test/test_helper.rb")
42 test.verbose = false
43 test.warning = false
44 end
45
fcea4b9 @bblimke Run WebMock specs against both EM-HTTP-Request 0.3 and EM-HTTP-Request 1...
authored
46
af4c054 @bblimke Fixed Net::HTTP adapter to not break normal Net::HTTP behaviour when net...
authored
47 task :default => [:spec, :spec_http_without_webmock, :test, :minitest]
bb63e1f Imported project to github
Bartosz Blimke authored
48
2607add @bblimke Updated Rakefile to use new RDoc::Task
authored
49 require 'rdoc/task'
50 RDoc::Task.new do |rdoc|
d73224f @jcf Rip out jeweler and use bundler instead
jcf authored
51 $:.push File.expand_path('../lib', __FILE__)
52 require 'webmock/version'
bb63e1f Imported project to github
Bartosz Blimke authored
53
54 rdoc.rdoc_dir = 'rdoc'
d73224f @jcf Rip out jeweler and use bundler instead
jcf authored
55 rdoc.title = "webmock #{WebMock::VERSION}"
bb63e1f Imported project to github
Bartosz Blimke authored
56 rdoc.rdoc_files.include('README*')
57 rdoc.rdoc_files.include('lib/webmock/webmock.rb')
58 end
Something went wrong with that request. Please try again.