mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
check JS availability for CoffeeScript tests properly
This commit is contained in:
parent
e0e4388633
commit
91992c99f4
2 changed files with 7 additions and 1 deletions
1
Gemfile
1
Gemfile
|
@ -39,5 +39,4 @@ platforms :mri_18 do
|
|||
# bundler platforms are broken
|
||||
next if RUBY_ENGINE != 'ruby' or RUBY_VERSION > "1.8"
|
||||
gem 'rcov', :group => 'rcov'
|
||||
gem 'therubyracer', :group => 'coffee-script'
|
||||
end
|
||||
|
|
|
@ -2,6 +2,13 @@ require File.dirname(__FILE__) + '/helper'
|
|||
|
||||
begin
|
||||
require 'coffee-script'
|
||||
require 'execjs'
|
||||
|
||||
begin
|
||||
ExecJS.compile '1'
|
||||
rescue Exception
|
||||
raise LoadError, 'unable to execute JavaScript'
|
||||
end
|
||||
|
||||
class CoffeeTest < Test::Unit::TestCase
|
||||
def coffee_app(options = {}, &block)
|
||||
|
|
Loading…
Reference in a new issue