Skip to content

Commit

Permalink
add first class support for trinidad, fixes sinatra#482
Browse files Browse the repository at this point in the history
  • Loading branch information
rkh committed May 13, 2012
1 parent 700d5b2 commit cab56ed
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 13 deletions.
1 change: 0 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ if RUBY_ENGINE == 'jruby'
gem 'nokogiri', '!= 1.5.0'
gem 'jruby-openssl'
gem 'trinidad'
gem 'mizuno'
else
gem 'yajl-ruby'
gem 'nokogiri'
Expand Down
1 change: 0 additions & 1 deletion lib/sinatra/base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1617,7 +1617,6 @@ class << self
server.unshift 'controll_tower'
else
server.unshift 'mongrel' if ruby_engine.nil?
server.unshift 'mizuno' if ruby_engine =='jruby'
server.unshift 'puma' if ruby_engine != 'rbx'
server.unshift 'thin' if ruby_engine != 'jruby'
server.unshift 'puma' if ruby_engine == 'rbx'
Expand Down
10 changes: 2 additions & 8 deletions test/integration_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -134,21 +134,15 @@ def trinidad?
name.to_s == "trinidad"
end

def mizuno?
name.to_s == "mizuno"
end

def warnings
log.scan(%r[(?:\(eval|lib/sinatra).*warning:.*$])
end

def run_test(target, &block)
retries ||= 3
target.server = self
Timeout.timeout(60) do
run unless alive?
target.instance_eval(&block)
end
run unless alive?
target.instance_eval(&block)
rescue Exception => error
retries -= 1
kill
Expand Down
4 changes: 1 addition & 3 deletions test/integration_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class IntegrationTest < Test::Unit::TestCase
end

it 'streams' do
next if server.webrick? or server.trinidad? or server.mizuno?
next if server.webrick? or server.trinidad?
times, chunks = [Time.now], []
server.get_stream do |chunk|
next if chunk.empty?
Expand Down Expand Up @@ -70,8 +70,6 @@ class IntegrationTest < Test::Unit::TestCase
end

it 'starts the correct server' do
next if RUBY_ENGINE == 'jruby'

exp = %r{
==\sSinatra/#{Sinatra::VERSION}\s
has\staken\sthe\sstage\son\s\d+\sfor\sdevelopment\s
Expand Down

0 comments on commit cab56ed

Please sign in to comment.