Skip to content
This repository has been archived by the owner on May 12, 2018. It is now read-only.

Commit

Permalink
Fix commit stats. Version up to 1.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
dzaporozhets committed May 14, 2013
1 parent f8618ed commit fda2e54
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
v 1.2.1
- fixed commit stats

v 1.2.0
- Use gitlab-grit instead of grit
- removed grit_ext dependency also
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
gitlab_git (1.1.0)
gitlab_git (1.2.0)
activesupport (~> 3.2.13)
github-linguist (~> 2.3.4)
gitlab-grit (~> 2.5.1)
Expand Down
2 changes: 1 addition & 1 deletion gitlab_git.gemspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = 'gitlab_git'
s.version = '1.2.0'
s.version = '1.2.1'
s.date = '2013-04-29'
s.summary = "Gitlab::Git library"
s.description = "GitLab wrapper around git objects"
Expand Down
2 changes: 1 addition & 1 deletion lib/gitlab_git/commit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ def tree
end

def stats
raw_commit.tree
raw_commit.stats
end

def to_patch
Expand Down
7 changes: 7 additions & 0 deletions spec/commit_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,13 @@
its(:message) { should == sample_commit_hash[:message]}
end

describe :stats do
subject { commit.stats }

its(:additions) { should eq(2) }
its(:deletions) { should eq(1) }
end

describe :to_diff do
subject { commit.to_diff }

Expand Down

0 comments on commit fda2e54

Please sign in to comment.