Skip to content

Commit

Permalink
Fix linter error
Browse files Browse the repository at this point in the history
  • Loading branch information
ahangarha committed Apr 5, 2024
1 parent 46a8af0 commit e26527c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/react_on_rails/git_utils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

module ReactOnRails
module GitUtils
def self.uncommitted_changes?(message_handler, git_installed = true)
def self.uncommitted_changes?(message_handler, git_installed: true)
return false if ENV["COVERAGE"] == "true"

status = `git status --porcelain`
Expand Down
6 changes: 3 additions & 3 deletions spec/react_on_rails/git_utils_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module ReactOnRails
expect(message_handler).to receive(:add_error)
.with("You have uncommitted code. Please commit or stash your changes before continuing")

expect(described_class.uncommitted_changes?(message_handler, true)).to be(true)
expect(described_class.uncommitted_changes?(message_handler, git_installed: true)).to be(true)
end
end

Expand All @@ -24,7 +24,7 @@ module ReactOnRails
allow(described_class).to receive(:`).with("git status --porcelain").and_return("")
expect(message_handler).not_to receive(:add_error)

expect(described_class.uncommitted_changes?(message_handler, true)).to be(false)
expect(described_class.uncommitted_changes?(message_handler, git_installed: true)).to be(false)
end
end

Expand All @@ -36,7 +36,7 @@ module ReactOnRails
expect(message_handler).to receive(:add_error)
.with("You do not have Git installed. Please install Git, and commit your changes before continuing")

expect(described_class.uncommitted_changes?(message_handler, false)).to be(true)
expect(described_class.uncommitted_changes?(message_handler, git_installed: false)).to be(true)
end
end
end
Expand Down

0 comments on commit e26527c

Please sign in to comment.