b13fd43a2e
Also, don't ever muck with the load paths or rubygems without first trying to require the library without doing so.
26 lines
688 B
Ruby
26 lines
688 B
Ruby
need_gems = false
|
|
|
|
lib_dir = File.expand_path(File.join(File.dirname(__FILE__), '..', 'lib'))
|
|
$:.unshift(lib_dir) unless $:.include?(lib_dir)
|
|
|
|
# allows testing with edge Haml by creating a test/haml symlink
|
|
linked_haml = File.dirname(__FILE__) + '/haml'
|
|
|
|
if File.exists?(linked_haml) && !$:.include?(linked_haml + '/lib')
|
|
puts "[ using linked Haml ]"
|
|
$:.unshift linked_haml + '/lib'
|
|
require 'sass'
|
|
else
|
|
need_gems = true
|
|
end
|
|
|
|
require 'rubygems' if need_gems
|
|
|
|
require 'compass'
|
|
|
|
require 'test/unit'
|
|
|
|
require File.join(File.dirname(__FILE__), 'test_case_helper')
|
|
require File.join(File.dirname(__FILE__), 'io_helper')
|
|
require File.join(File.dirname(__FILE__), 'command_line_helper')
|