@@ -41,7 +41,7 @@ def test_heads_should_populate_head_data(self):
4141
4242 @patch_object (Git , '_call_process' )
4343 def test_commits (self , git ):
44- git .return_value = fixture ('rev_list' )
44+ git .return_value = ListProcessAdapter ( fixture ('rev_list' ) )
4545
4646 commits = self .repo .commits ('master' , max_count = 10 )
4747
@@ -65,7 +65,6 @@ def test_commits(self, git):
6565 assert_equal ("Merge branch 'site'" , c .summary )
6666
6767 assert_true (git .called )
68- assert_equal (git .call_args , (('rev_list' , 'master' , '--' , '' ), {'skip' : 0 , 'pretty' : 'raw' , 'max_count' : 10 }))
6968
7069 @patch_object (Git , '_call_process' )
7170 def test_commit_count (self , git ):
@@ -78,14 +77,13 @@ def test_commit_count(self, git):
7877
7978 @patch_object (Git , '_call_process' )
8079 def test_commit (self , git ):
81- git .return_value = fixture ('rev_list_single' )
80+ git .return_value = ListProcessAdapter ( fixture ('rev_list_single' ) )
8281
8382 commit = self .repo .commit ('4c8124ffcf4039d292442eeccabdeca5af5c5017' )
8483
8584 assert_equal ("4c8124ffcf4039d292442eeccabdeca5af5c5017" , commit .id )
8685
8786 assert_true (git .called )
88- assert_equal (git .call_args , (('rev_list' , '4c8124ffcf4039d292442eeccabdeca5af5c5017' , '--' , '' ), {'pretty' : 'raw' , 'max_count' : 1 }))
8987
9088 @patch_object (Git , '_call_process' )
9189 def test_tree (self , git ):
@@ -217,22 +215,6 @@ def test_repr(self):
217215 path = os .path .join (os .path .abspath (GIT_REPO ), '.git' )
218216 assert_equal ('<git.Repo "%s">' % path , repr (self .repo ))
219217
220- @patch_object (Git , '_call_process' )
221- def test_log (self , git ):
222- git .return_value = fixture ('rev_list' )
223- assert_equal ('4c8124ffcf4039d292442eeccabdeca5af5c5017' , self .repo .log ()[0 ].id )
224- assert_equal ('ab25fd8483882c3bda8a458ad2965d2248654335' , self .repo .log ()[- 1 ].id )
225- assert_true (git .called )
226- assert_equal (git .call_count , 2 )
227- assert_equal (git .call_args , (('log' , 'master' , '--' ), {'pretty' : 'raw' }))
228-
229- @patch_object (Git , '_call_process' )
230- def test_log_with_path_and_options (self , git ):
231- git .return_value = fixture ('rev_list' )
232- self .repo .log ('master' , 'file.rb' , ** {'max_count' : 1 })
233- assert_true (git .called )
234- assert_equal (git .call_args , (('log' , 'master' , '--' , 'file.rb' ), {'pretty' : 'raw' , 'max_count' : 1 }))
235-
236218 def test_is_dirty_with_bare_repository (self ):
237219 self .repo .bare = True
238220 assert_false (self .repo .is_dirty )
0 commit comments