From c286c66f57e4fd716fe1746363f8c7cf4205cee3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9my=20Coutable?= Date: Tue, 10 Apr 2018 16:07:47 +0200 Subject: Move Settings to its own file, isolate it from Rails and introduce Gitlab.root MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Rémy Coutable --- spec/lib/gitlab_spec.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'spec/lib/gitlab_spec.rb') diff --git a/spec/lib/gitlab_spec.rb b/spec/lib/gitlab_spec.rb index e734c12f6dd..da146e24893 100644 --- a/spec/lib/gitlab_spec.rb +++ b/spec/lib/gitlab_spec.rb @@ -3,6 +3,12 @@ require 'fast_spec_helper' require_dependency 'gitlab' describe Gitlab do + describe '.root' do + it 'returns the root path of the app' do + expect(described_class.root).to eq(Pathname.new(File.expand_path('../..', __dir__))) + end + end + describe '.com?' do it 'is true when on GitLab.com' do stub_config_setting(url: 'https://gitlab.com') -- cgit v1.2.1