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>2021-06-28 12:08:19 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-06-28 12:08:19 +0300
commit79659fe1fe45f2bdd13cd1a3980fbf1714caad57 (patch)
tree6dc2d9e7a3543d5346337c5056331c70f736e950 /spec/tooling/danger
parent6047d21a899cba25dfb554cca1776fed689dc951 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/tooling/danger')
-rw-r--r--spec/tooling/danger/feature_flag_spec.rb18
-rw-r--r--spec/tooling/danger/project_helper_spec.rb38
2 files changed, 37 insertions, 19 deletions
diff --git a/spec/tooling/danger/feature_flag_spec.rb b/spec/tooling/danger/feature_flag_spec.rb
index 5e495cd43c6..74e19d8f535 100644
--- a/spec/tooling/danger/feature_flag_spec.rb
+++ b/spec/tooling/danger/feature_flag_spec.rb
@@ -87,7 +87,11 @@ RSpec.describe Tooling::Danger::FeatureFlag do
let(:feature_flag_path) { 'config/feature_flags/development/entry.yml' }
let(:group) { 'group::source code' }
let(:raw_yaml) do
- YAML.dump('group' => group)
+ YAML.dump(
+ 'group' => group,
+ 'default_enabled' => true,
+ 'rollout_issue_url' => 'https://gitlab.com/gitlab-org/gitlab/-/issues/1'
+ )
end
subject(:found) { described_class.new(feature_flag_path) }
@@ -109,6 +113,18 @@ RSpec.describe Tooling::Danger::FeatureFlag do
end
end
+ describe '#default_enabled' do
+ it 'returns the default_enabled found in the YAML' do
+ expect(found.default_enabled).to eq(true)
+ end
+ end
+
+ describe '#rollout_issue_url' do
+ it 'returns the rollout_issue_url found in the YAML' do
+ expect(found.rollout_issue_url).to eq('https://gitlab.com/gitlab-org/gitlab/-/issues/1')
+ end
+ end
+
describe '#group_match_mr_label?' do
subject(:result) { found.group_match_mr_label?(mr_group_label) }
diff --git a/spec/tooling/danger/project_helper_spec.rb b/spec/tooling/danger/project_helper_spec.rb
index 5edec1c5229..d2d706fad3f 100644
--- a/spec/tooling/danger/project_helper_spec.rb
+++ b/spec/tooling/danger/project_helper_spec.rb
@@ -56,24 +56,26 @@ RSpec.describe Tooling::Danger::ProjectHelper do
'ee/doc/foo' | [:unknown]
'ee/README' | [:unknown]
- 'app/assets/foo' | [:frontend]
- 'app/views/foo' | [:frontend]
- 'public/foo' | [:frontend]
- 'scripts/frontend/foo' | [:frontend]
- 'spec/javascripts/foo' | [:frontend]
- 'spec/frontend/bar' | [:frontend]
- 'vendor/assets/foo' | [:frontend]
- 'babel.config.js' | [:frontend]
- 'jest.config.js' | [:frontend]
- 'package.json' | [:frontend]
- 'yarn.lock' | [:frontend]
- 'config/foo.js' | [:frontend]
- 'config/deep/foo.js' | [:frontend]
-
- 'ee/app/assets/foo' | [:frontend]
- 'ee/app/views/foo' | [:frontend]
- 'ee/spec/javascripts/foo' | [:frontend]
- 'ee/spec/frontend/bar' | [:frontend]
+ 'app/assets/foo' | [:frontend]
+ 'app/views/foo' | [:frontend]
+ 'public/foo' | [:frontend]
+ 'scripts/frontend/foo' | [:frontend]
+ 'spec/javascripts/foo' | [:frontend]
+ 'spec/frontend/bar' | [:frontend]
+ 'spec/frontend_integration/bar' | [:frontend]
+ 'vendor/assets/foo' | [:frontend]
+ 'babel.config.js' | [:frontend]
+ 'jest.config.js' | [:frontend]
+ 'package.json' | [:frontend]
+ 'yarn.lock' | [:frontend]
+ 'config/foo.js' | [:frontend]
+ 'config/deep/foo.js' | [:frontend]
+
+ 'ee/app/assets/foo' | [:frontend]
+ 'ee/app/views/foo' | [:frontend]
+ 'ee/spec/javascripts/foo' | [:frontend]
+ 'ee/spec/frontend/bar' | [:frontend]
+ 'ee/spec/frontend_integration/bar' | [:frontend]
'.gitlab/ci/frontend.gitlab-ci.yml' | %i[frontend engineering_productivity]