mirror of
https://github.com/wahyd4/gitlabhq.git
synced 2026-08-09 12:46:07 +10:00
Minor refactoring on Gitlab::Git
This commit is contained in:
+4
-3
@@ -1,8 +1,9 @@
|
||||
module Gitlab
|
||||
module Git
|
||||
BLANK_SHA = '0' * 40
|
||||
TAG_REF_PREFIX = "refs/tags/"
|
||||
BRANCH_REF_PREFIX = "refs/heads/"
|
||||
# '0' * 40 -- this was easyer to freeze
|
||||
BLANK_SHA = "0000000000000000000000000000000000000000".freeze
|
||||
TAG_REF_PREFIX = "refs/tags/".freeze
|
||||
BRANCH_REF_PREFIX = "refs/heads/".freeze
|
||||
|
||||
class << self
|
||||
def ref_name(ref)
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe Gitlab::Git do
|
||||
describe "BLANK_SHA" do
|
||||
it "is a string of 40 zero's" do
|
||||
expect(Gitlab::Git::BLANK_SHA).to eq('0' * 40)
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user