-
Notifications
You must be signed in to change notification settings - Fork 533
Disable GPG Signing in Test Config #467
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
If a user has GPG signing set to true in their global .gitconfig file, the test suite will fail. This is because the test suit now includes a check of a commit message (the `test_commit_with_no_verify` test in `tests/units/test_lib.rb`) but did not update the test config file. This commit updates the config file to set the `gpgsign` option to false. Signed-off-by: Michael Camilleri <mike@inqk.net>
I tested this change and found that the test suite still fails if
$ git config --global --unset commit.gpgsign
$ git clone https://github.com/ruby-git/ruby-git.git ruby-git-gpgsign
...
$ cd ruby-git-gpgsign
$ bundle
...
$
$ bundle exec rake test
...
122 tests, 486 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
...
$
$ git config --global commit.gpgsign true
...
$
$ bundle exec rake test
...
122 tests, 356 assertions, 1 failures, 27 errors, 0 pendings, 0 omissions, 0 notifications
77.0492% passed
...
$
$ git fetch origin +refs/pull/467/merge
...
$ git checkout FETCH_HEAD
...
HEAD is now at e338a88 Merge 0c9cbcd9a8b352e44c4bf84bb483c6a19ee21233 into 861eb71e1c266606eefacf7ebd4bee4f34bee5de
$
$ cat tests/files/working/dot_git/config
[user]
name = Scott Chacon
email = schacon@gmail.com
[commit]
gpgsign = false
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[gui]
geometry = 986x682+365+124 211 500
[remote "working"]
url = ../working.git
fetch = +refs/heads/*:refs/remotes/working/*
$
$ bundle exec rake test
...
122 tests, 358 assertions, 0 failures, 26 errors, 0 pendings, 0 omissions, 0 notifications
78.6885% passed
...
$ |
@jcouball Thanks for the quick response. I'm not seeing the errors that you are seeing. My guess is that you're getting that result because you've enabled the
That error goes away once I put the |
Ah, yes! Your guess was spot on. Once I set the # not a real signing key, of course :)
$ git config --global user.signingkey F2C7AB29
$ bundle exec rake test
...
122 tests, 486 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
...
$ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your contribution! Looks good.
@jcouball That's great! Thanks for the merge! :) |
Your checklist for this pull request
Description
If a user has GPG signing set to true in their global
.gitconfig
file, the test suite will fail. This is because the test suit now includes a check of a commit message (thetest_commit_with_no_verify
test intests/units/test_lib.rb
that was added by #454) but did not update the test config file. This commit updates the config file to set thegpgsign
option to false.