diff options
author | Bob Van Landuyt <bob@gitlab.com> | 2017-05-29 20:28:56 +0200 |
---|---|---|
committer | Bob Van Landuyt <bob@gitlab.com> | 2017-05-31 14:40:17 +0200 |
commit | 7fc49ec13fa0719397e00b89f2c8b3f4c6f908e2 (patch) | |
tree | 83d567b9cca7d4dde4775708aa390311304dd125 /spec/lib | |
parent | bd83ca1017e33fc09cc934f705d1070fbe4ab255 (diff) | |
download | gitlab-ce-bvl-move-gitlab-git-encodinghelper.tar.gz |
Rename Gitlab::Git::EncodingHelper to Gitlab::EncodingHelperbvl-move-gitlab-git-encodinghelper
Diffstat (limited to 'spec/lib')
-rw-r--r-- | spec/lib/constraints/group_url_constrainer_spec.rb | 6 | ||||
-rw-r--r-- | spec/lib/constraints/project_url_constrainer_spec.rb | 6 | ||||
-rw-r--r-- | spec/lib/constraints/user_url_constrainer_spec.rb | 6 | ||||
-rw-r--r-- | spec/lib/gitlab/encoding_helper_spec.rb (renamed from spec/lib/gitlab/git/encoding_helper_spec.rb) | 4 | ||||
-rw-r--r-- | spec/lib/gitlab/git/repository_spec.rb | 2 |
5 files changed, 3 insertions, 21 deletions
diff --git a/spec/lib/constraints/group_url_constrainer_spec.rb b/spec/lib/constraints/group_url_constrainer_spec.rb index bc767f46d8e..db680489a8d 100644 --- a/spec/lib/constraints/group_url_constrainer_spec.rb +++ b/spec/lib/constraints/group_url_constrainer_spec.rb @@ -30,12 +30,6 @@ describe GroupUrlConstrainer, lib: true do it { expect(subject.matches?(request)).to be_falsey } end - context 'invalid encoding' do - let(:request) { build_request("hi \255") } - - it { expect(subject.matches?(request)).to be_falsey } - end - context 'when the request matches a redirect route' do context 'for a root group' do let!(:redirect_route) { group.redirect_routes.create!(path: 'gitlabb') } diff --git a/spec/lib/constraints/project_url_constrainer_spec.rb b/spec/lib/constraints/project_url_constrainer_spec.rb index 4b1a1e2f607..b6884e37aa3 100644 --- a/spec/lib/constraints/project_url_constrainer_spec.rb +++ b/spec/lib/constraints/project_url_constrainer_spec.rb @@ -39,12 +39,6 @@ describe ProjectUrlConstrainer, lib: true do it { expect(subject.matches?(request)).to be_falsey } end end - - context 'invalid encoding' do - let(:request) { build_request("hi \255", "bye \255") } - - it { expect(subject.matches?(request)).to be_falsey } - end end def build_request(namespace, project, method = 'GET') diff --git a/spec/lib/constraints/user_url_constrainer_spec.rb b/spec/lib/constraints/user_url_constrainer_spec.rb index 3a53834a875..ed69b830979 100644 --- a/spec/lib/constraints/user_url_constrainer_spec.rb +++ b/spec/lib/constraints/user_url_constrainer_spec.rb @@ -30,12 +30,6 @@ describe UserUrlConstrainer, lib: true do it { expect(subject.matches?(request)).to be_falsey } end end - - context 'invalid encoding' do - let(:request) { build_request("hi \255") } - - it { expect(subject.matches?(request)).to be_falsey } - end end def build_request(username, method = 'GET') diff --git a/spec/lib/gitlab/git/encoding_helper_spec.rb b/spec/lib/gitlab/encoding_helper_spec.rb index 48fc817d857..1482ef7132d 100644 --- a/spec/lib/gitlab/git/encoding_helper_spec.rb +++ b/spec/lib/gitlab/encoding_helper_spec.rb @@ -1,7 +1,7 @@ require "spec_helper" -describe Gitlab::Git::EncodingHelper do - let(:ext_class) { Class.new { extend Gitlab::Git::EncodingHelper } } +describe Gitlab::EncodingHelper do + let(:ext_class) { Class.new { extend Gitlab::EncodingHelper } } let(:binary_string) { File.read(Rails.root + "spec/fixtures/dk.png") } describe '#encode!' do diff --git a/spec/lib/gitlab/git/repository_spec.rb b/spec/lib/gitlab/git/repository_spec.rb index cb107c6d1f9..9fb9eb00d53 100644 --- a/spec/lib/gitlab/git/repository_spec.rb +++ b/spec/lib/gitlab/git/repository_spec.rb @@ -1,7 +1,7 @@ require "spec_helper" describe Gitlab::Git::Repository, seed_helper: true do - include Gitlab::Git::EncodingHelper + include Gitlab::EncodingHelper let(:repository) { Gitlab::Git::Repository.new('default', TEST_REPO_PATH) } |