Permalink
Browse files

provide explicit git author for test commits

References #216
  • Loading branch information...
1 parent 0b377ad commit c557de6009cb97f02aa8934b1388a64421392beb @mislav mislav committed Jul 20, 2012
Showing with 9 additions and 3 deletions.
  1. +3 −3 features/steps.rb
  2. +6 −0 features/support/env.rb
View
@@ -51,14 +51,14 @@
end
Given /^there is a commit named "([^"]+)"$/ do |name|
- run_silent %(git commit --quiet --allow-empty --allow-empty-message -m '')
- run_silent %(git commit --quiet --allow-empty --allow-empty-message -m '')
+ empty_commit
+ empty_commit
run_silent %(git tag #{name})
run_silent %(git reset --quiet --hard HEAD^)
end
Given /^I am on the "([^"]+)" branch(?: with upstream "([^"]+)")?$/ do |name, upstream|
- run_silent %(git commit --quiet --allow-empty --allow-empty-message -m '')
+ empty_commit
if upstream
full_upstream = ".git/refs/remotes/#{upstream}"
in_current_dir do
@@ -126,6 +126,12 @@ def run_silent cmd
end
end
+ def empty_commit
+ run_silent "git commit --quiet -m ''" <<
+ " --allow-empty --allow-empty-message" <<
+ " --author 'Hub <hub@test.local>'"
+ end
+
# Aruba unnecessarily creates new Announcer instance on each invocation
def announcer
@announcer ||= super

0 comments on commit c557de6

Please sign in to comment.