shut up when no script/hooks dir, but there is a .git dir
This commit is contained in:
parent
3761c79d25
commit
b29794152f
@ -40,6 +40,15 @@ Feature: CLI
|
||||
When I run "bin/penchant gemfile remote" in the "tmp" directory
|
||||
Then the output should include "git hooks not installed"
|
||||
|
||||
Scenario: Run in a project where there are no git hooks, but there is a git repo
|
||||
Given I have the file "tmp/Gemfile.penchant" with the content:
|
||||
"""
|
||||
gem 'rake'
|
||||
"""
|
||||
Given I have the directory "tmp/.git"
|
||||
When I run "bin/penchant gemfile remote" in the "tmp" directory
|
||||
Then the output should not include "git hooks not installed"
|
||||
|
||||
Scenario: Run in a project where git hooks are set up
|
||||
Given I have the file "tmp/Gemfile.penchant" with the content:
|
||||
"""
|
||||
|
@ -0,0 +1,3 @@
|
||||
Given /^I have the directory "(.*?)"$/ do |dir|
|
||||
FileUtils.mkdir_p dir
|
||||
end
|
@ -13,6 +13,9 @@ module Penchant
|
||||
return false if !File.expand_path(File.readlink(target)) == File.expand_path(file)
|
||||
end
|
||||
|
||||
true
|
||||
else
|
||||
# no script/hooks dir, so we must not want them
|
||||
true
|
||||
end
|
||||
end
|
||||
|
@ -1,3 +1,3 @@
|
||||
module Penchant
|
||||
VERSION = "0.2.14"
|
||||
VERSION = "0.2.15"
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user