Rename TEST_FOLDER to TEST_DIRECTORY
This commit is contained in:
parent
dbe82909a3
commit
0505582507
@ -17,8 +17,8 @@ class CleanerTests < Test::Unit::TestCase
|
||||
def test_clean_file
|
||||
@f.bin.mkpath
|
||||
@f.lib.mkpath
|
||||
cp "#{TEST_FOLDER}/mach/a.out", @f.bin
|
||||
cp Dir["#{TEST_FOLDER}/mach/*.dylib"], @f.lib
|
||||
cp "#{TEST_DIRECTORY}/mach/a.out", @f.bin
|
||||
cp Dir["#{TEST_DIRECTORY}/mach/*.dylib"], @f.lib
|
||||
|
||||
Cleaner.new(@f).clean
|
||||
|
||||
|
||||
@ -2,11 +2,11 @@ require 'testing_env'
|
||||
|
||||
class MachOPathnameTests < Test::Unit::TestCase
|
||||
def dylib_path(name)
|
||||
Pathname.new("#{TEST_FOLDER}/mach/#{name}.dylib")
|
||||
Pathname.new("#{TEST_DIRECTORY}/mach/#{name}.dylib")
|
||||
end
|
||||
|
||||
def bundle_path(name)
|
||||
Pathname.new("#{TEST_FOLDER}/mach/#{name}.bundle")
|
||||
Pathname.new("#{TEST_DIRECTORY}/mach/#{name}.bundle")
|
||||
end
|
||||
|
||||
def test_fat_dylib
|
||||
@ -49,7 +49,7 @@ class MachOPathnameTests < Test::Unit::TestCase
|
||||
end
|
||||
|
||||
def test_mach_o_executable
|
||||
pn = Pathname.new("#{TEST_FOLDER}/mach/a.out")
|
||||
pn = Pathname.new("#{TEST_DIRECTORY}/mach/a.out")
|
||||
assert pn.universal?
|
||||
assert !pn.i386?
|
||||
assert !pn.x86_64?
|
||||
@ -101,7 +101,7 @@ class MachOPathnameTests < Test::Unit::TestCase
|
||||
end
|
||||
|
||||
def test_non_mach_o
|
||||
pn = Pathname.new("#{TEST_FOLDER}/tarballs/testball-0.1.tbz")
|
||||
pn = Pathname.new("#{TEST_DIRECTORY}/tarballs/testball-0.1.tbz")
|
||||
assert !pn.universal?
|
||||
assert !pn.i386?
|
||||
assert !pn.x86_64?
|
||||
|
||||
@ -3,12 +3,12 @@ require 'formula'
|
||||
require 'testball'
|
||||
|
||||
class PatchingTests < Test::Unit::TestCase
|
||||
PATCH_URL_A = "file:///#{TEST_FOLDER}/patches/noop-a.diff"
|
||||
PATCH_URL_B = "file:///#{TEST_FOLDER}/patches/noop-b.diff"
|
||||
PATCH_URL_A = "file:///#{TEST_DIRECTORY}/patches/noop-a.diff"
|
||||
PATCH_URL_B = "file:///#{TEST_DIRECTORY}/patches/noop-b.diff"
|
||||
|
||||
def formula(&block)
|
||||
super do
|
||||
url "file:///#{TEST_FOLDER}/tarballs/testball-0.1.tbz"
|
||||
url "file:///#{TEST_DIRECTORY}/tarballs/testball-0.1.tbz"
|
||||
sha1 "482e737739d946b7c8cbaf127d9ee9c148b999f5"
|
||||
class_eval(&block)
|
||||
end
|
||||
|
||||
@ -38,7 +38,7 @@ class UpdaterTests < Test::Unit::TestCase
|
||||
end
|
||||
|
||||
def self.fixture_data
|
||||
@fixture_data ||= YAML.load_file("#{TEST_FOLDER}/fixtures/updater_fixture.yaml")
|
||||
@fixture_data ||= YAML.load_file("#{TEST_DIRECTORY}/fixtures/updater_fixture.yaml")
|
||||
end
|
||||
|
||||
def setup
|
||||
|
||||
@ -3,7 +3,7 @@ require 'formula'
|
||||
class TestBall < Formula
|
||||
def initialize(name="test_ball", path=nil)
|
||||
self.class.instance_eval do
|
||||
stable.url "file:///#{TEST_FOLDER}/tarballs/testball-0.1.tbz"
|
||||
stable.url "file:///#{TEST_DIRECTORY}/tarballs/testball-0.1.tbz"
|
||||
stable.sha1 "482e737739d946b7c8cbaf127d9ee9c148b999f5"
|
||||
end
|
||||
super
|
||||
|
||||
@ -54,7 +54,7 @@ end
|
||||
at_exit { HOMEBREW_PREFIX.parent.rmtree }
|
||||
|
||||
# Test fixtures and files can be found relative to this path
|
||||
TEST_FOLDER = File.dirname(File.expand_path(__FILE__))
|
||||
TEST_DIRECTORY = File.dirname(File.expand_path(__FILE__))
|
||||
|
||||
def shutup
|
||||
if ARGV.verbose?
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user