Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-03-04 06:19:33 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-03-04 06:19:33 +0300
commitb6927b3dd66fc3e5954f866c692b0ee8e276ec57 (patch)
tree362aee92f7d4829af1a7da6a39354327f17157ad /spec/lib/gitlab_spec.rb
parent3e1ab188315ef6b90d0473bc2cbd81b7e931c0f6 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/lib/gitlab_spec.rb')
-rw-r--r--spec/lib/gitlab_spec.rb15
1 files changed, 11 insertions, 4 deletions
diff --git a/spec/lib/gitlab_spec.rb b/spec/lib/gitlab_spec.rb
index cf3239da5f5..1cc4e69b3d9 100644
--- a/spec/lib/gitlab_spec.rb
+++ b/spec/lib/gitlab_spec.rb
@@ -112,11 +112,18 @@ RSpec.describe Gitlab do
expect(described_class.com?).to eq false
end
- it 'is true when GITLAB_SIMULATE_SAAS is true' do
+ it 'is true when GITLAB_SIMULATE_SAAS is true and in development' do
+ stub_rails_env('development')
stub_env('GITLAB_SIMULATE_SAAS', '1')
expect(described_class.com?).to eq true
end
+
+ it 'is false when GITLAB_SIMULATE_SAAS is true and in test' do
+ stub_env('GITLAB_SIMULATE_SAAS', '1')
+
+ expect(described_class.com?).to eq false
+ end
end
describe '.com' do
@@ -239,8 +246,8 @@ RSpec.describe Gitlab do
stub_env('GITLAB_SIMULATE_SAAS', '1')
end
- it 'is true when test env' do
- expect(subject).to eq true
+ it 'is false when test env' do
+ expect(subject).to eq false
end
it 'is true when dev env' do
@@ -249,7 +256,7 @@ RSpec.describe Gitlab do
expect(subject).to eq true
end
- it 'is false when env is not dev or test' do
+ it 'is false when env is not dev' do
stub_rails_env('production')
expect(subject).to eq false