Fix brew cask style with relative paths.
This commit is contained in:
parent
178db5dca5
commit
a838b372de
@ -31,7 +31,7 @@ module Cask
|
||||
@cask_paths ||= if args.empty?
|
||||
Tap.map(&:cask_dir).select(&:directory?)
|
||||
elsif args.any? { |file| File.exist?(file) }
|
||||
args
|
||||
args.map { |path| Pathname(path).expand_path }
|
||||
else
|
||||
casks.map(&:sourcefile_path)
|
||||
end
|
||||
|
||||
@ -106,7 +106,10 @@ describe Cask::Cmd::Style, :cask do
|
||||
end
|
||||
|
||||
it "treats all tokens as paths" do
|
||||
expect(subject).to eq(tokens)
|
||||
expect(subject).to eq [
|
||||
Pathname("adium").expand_path,
|
||||
Pathname("Casks/dropbox.rb").expand_path,
|
||||
]
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user