Skip to content

Commit

Permalink
Fix spec compatibility with recent git versions (#854)
Browse files Browse the repository at this point in the history
The original array was defining the shellwords like this:
`["git", "commit", "-m", "\"Resolve", "conflicts\"", "-i", "some-file"]`

This combined with the most recent git version failed with:
```
error: pathspec 'conflicts"' did not match any file(s) known to git
```

This PR just simplifies the commit message to work with the %w array
literal.
  • Loading branch information
anakinj authored Aug 11, 2024
1 parent 5ff9d5e commit 5a3d68e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion spec/integration/resolving_cherry_pick_conflict_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require 'spec_helper'

describe 'resolving cherry-pick conflicts' do
subject { shell(%w[git commit -m "Resolve conflicts" -i some-file]) }
subject { shell(%w[git commit -m Test -i some-file]) }

let(:config) { <<-YML }
PreCommit:
Expand Down
2 changes: 1 addition & 1 deletion spec/integration/resolving_merge_conflict_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require 'spec_helper'

describe 'resolving merge conflicts' do
subject { shell(%w[git commit -m "Resolve conflicts" -i some-file]) }
subject { shell(%w[git commit -m Test -i some-file]) }

around do |example|
repo do
Expand Down

0 comments on commit 5a3d68e

Please sign in to comment.