Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Run WebMock specs against both EM-HTTP-Request 0.3 and EM-HTTP-Reques…

…t 1.0 with EM-Synchrony on Ruby > 1.9.2 on Travis CI
  • Loading branch information...
commit fcea4b9b3bba779998610f59fe27ba9e1f83c624 1 parent b6ca337
@bblimke authored
Showing with 14 additions and 1 deletion.
  1. +2 −0  .travis.yml
  2. +5 −0 Gemfile
  3. +6 −0 Rakefile
  4. +1 −1  webmock.gemspec
View
2  .travis.yml
@@ -4,3 +4,5 @@ rvm:
- 1.9.3
- ree
- jruby
+
+script: "bundle exec rake && rake em_http_request_1_x_spec"
View
5 Gemfile
@@ -1,6 +1,11 @@
source 'http://rubygems.org/'
gemspec
+if ENV["EM_HTTP_REQUEST_1_X"]
+ gem 'em-http-request', '>= 1.0.0.beta.4'
+ gem 'em-synchrony', '>= 0.3.0.beta.1'
+end
+
group :development do
gem 'rake'
View
6 Rakefile
@@ -25,6 +25,11 @@ RSpec::Core::RakeTask.new(:spec_http_without_webmock) do |t|
t.pattern = 'spec/real_net_http_spec.rb'
end
+
+task :em_http_request_1_x_spec do
+ sh "EM_HTTP_REQUEST_1_X=true bundle install && bundle exec rspec spec/em_http_request_spec.rb" if RUBY_VERSION >= "1.9.2"
+end
+
require 'rake/testtask'
Rake::TestTask.new(:test) do |test|
test.test_files = FileList["test/**/*.rb"].exclude("test/test_helper.rb")
@@ -38,6 +43,7 @@ Rake::TestTask.new(:minitest) do |test|
test.warning = false
end
+
task :default => [:spec, :spec_http_without_webmock, :test, :minitest]
require 'rdoc/task'
View
2  webmock.gemspec
@@ -20,7 +20,7 @@ Gem::Specification.new do |s|
s.add_development_dependency 'rspec', '>= 2.0.0'
s.add_development_dependency 'httpclient', '>= 2.1.5.2'
s.add_development_dependency 'patron', '>= 0.4.9'
- s.add_development_dependency 'em-http-request', '>= 0.2.14'
+ s.add_development_dependency 'em-http-request', '~> 0.3.0'
s.add_development_dependency 'curb', '>= 0.7.8'
s.add_development_dependency 'typhoeus', '>= 0.2.4'
s.add_development_dependency 'minitest', '>= 2.2.2'
Please sign in to comment.
Something went wrong with that request. Please try again.