Commit e636acd8 authored by Eloy Duran's avatar Eloy Duran

Create archives of git fixture repos.

parent ff706d09
banana-lib @ 0d06750e
Subproject commit 0d06750e78e5a6653dc0f66776a257052328c146
Subproject commit c807c4a9bff2af0ada17863065eb44bda0275a7d
......@@ -7,6 +7,10 @@ describe "Pod::Command" do
extend SpecHelper::Log
extend SpecHelper::TemporaryDirectory
before do
fixture('master-spec-repo.git') # ensure the archive is unpacked
end
it "creates the local spec-repos directory and creates a clone of the `master' repo" do
command = Pod::Command.parse('setup')
def command.master_repo_url; SpecHelper.fixture('master-spec-repo.git'); end
......
......@@ -7,7 +7,14 @@ module SpecHelper
ROOT = ::ROOT + 'spec/fixtures'
def fixture(name)
ROOT + name
file = ROOT + name
unless file.exist?
archive = Pathname.new(file.to_s + '.tar.gz')
if archive.exist?
system "cd '#{archive.dirname}' && tar -zxvf '#{archive}' > /dev/null 2>&1"
end
end
file
end
module_function :fixture
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment