mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
skip haml / sass tests when they fail to load due to stupid bullshit
Both haml and sass have the retarded behavior of trying to read a VERSION file outside their lib directory. Installing haml or sass like a sane person (i.e. into a shared lib directory) and they fail on require with ENOENT. Ugh.
This commit is contained in:
parent
8a7dd92e1c
commit
e1638a43ad
2 changed files with 11 additions and 0 deletions
|
@ -1,4 +1,6 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
|
||||
begin
|
||||
require 'haml'
|
||||
|
||||
class HAMLTest < Test::Unit::TestCase
|
||||
|
@ -88,3 +90,6 @@ class HAMLTest < Test::Unit::TestCase
|
|||
assert_match(/^<!DOCTYPE html PUBLIC (.*) HTML 4.01/, body)
|
||||
end
|
||||
end
|
||||
rescue
|
||||
warn "#{$!.to_s}: skipping haml tests"
|
||||
end
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
require File.dirname(__FILE__) + '/helper'
|
||||
|
||||
begin
|
||||
require 'sass'
|
||||
|
||||
class SassTest < Test::Unit::TestCase
|
||||
|
@ -77,3 +79,7 @@ class SassTest < Test::Unit::TestCase
|
|||
assert_equal "#sass {\n background-color: #FFF;\n color: #000;\n}\n", body
|
||||
end
|
||||
end
|
||||
|
||||
rescue
|
||||
warn "#{$!.to_s}: skipping sass tests"
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue