diff --git a/lib/git/lib.rb b/lib/git/lib.rb
index <HASH>..<HASH> 100644
--- a/lib/git/lib.rb
+++ b/lib/git/lib.rb
@@ -430,9 +430,13 @@ module Git
     end
     
     def revert(commitish, opts = {})
+      # Forcing --no-edit as default since it's not an interactive session.
+      opts = {:'no-edit' => true}.merge(opts)
+      
       arr_opts = []
-      arr_opts << '--no-edit' if opts[:no_edit] || opts[:'no-edit']
+      arr_opts << '--no-edit' if opts[:'no-edit'] 
       arr_opts << commitish
+
       command('revert', arr_opts)
     end
 
diff --git a/tests/units/test_index_ops.rb b/tests/units/test_index_ops.rb
index <HASH>..<HASH> 100644
--- a/tests/units/test_index_ops.rb
+++ b/tests/units/test_index_ops.rb
@@ -83,7 +83,7 @@ class TestIndexOps < Test::Unit::TestCase
         new_file('test-file2', 'blablahbla')
         g.add
         g.commit("second-commit")
-        second_commit = g.gcommit('HEAD')
+        g.gcommit('HEAD')
 
         commits = g.log(1e4).count
         g.revert(first_commit.sha)
Merge branch 'revert-support' of git://github.com/fasttracktool-dev/ruby-git into fasttracktool-dev-revert-support

Conflicts:
	lib/git/base.rb
	lib/git/lib.rb
	tests/units/test_index_ops.rb