mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-12-08 20:38:47 +00:00
Change FileBlob to accept a base path
This commit is contained in:
@@ -6,9 +6,12 @@ require 'mime/types'
|
||||
class TestBlob < Test::Unit::TestCase
|
||||
include Linguist
|
||||
|
||||
def fixtures_path
|
||||
File.expand_path("../fixtures/blob", __FILE__)
|
||||
end
|
||||
|
||||
def blob(name)
|
||||
path = File.expand_path("../fixtures/blob/#{name}", __FILE__)
|
||||
FileBlob.new(path, name)
|
||||
FileBlob.new(File.join(fixtures_path, name), fixtures_path)
|
||||
end
|
||||
|
||||
def test_name
|
||||
|
||||
Reference in New Issue
Block a user