1
0
Fork 0
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:
Ryan Tomayko 2010-03-15 19:20:55 -07:00
parent 8a7dd92e1c
commit e1638a43ad
2 changed files with 11 additions and 0 deletions

View file

@ -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

View file

@ -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