Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
343aa7da
Commit
343aa7da
authored
Jun 30, 2021
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab master
parents
7f6347ed
719c5885
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
36 additions
and
35 deletions
+36
-35
doc/user/packages/container_registry/index.md
doc/user/packages/container_registry/index.md
+1
-1
doc/user/packages/dependency_proxy/index.md
doc/user/packages/dependency_proxy/index.md
+3
-2
spec/models/integrations/base_issue_tracker_spec.rb
spec/models/integrations/base_issue_tracker_spec.rb
+6
-6
spec/models/integrations/bugzilla_spec.rb
spec/models/integrations/bugzilla_spec.rb
+5
-5
spec/models/integrations/campfire_spec.rb
spec/models/integrations/campfire_spec.rb
+2
-2
spec/models/integrations/confluence_spec.rb
spec/models/integrations/confluence_spec.rb
+4
-4
spec/models/integrations/datadog_spec.rb
spec/models/integrations/datadog_spec.rb
+1
-1
spec/models/integrations/external_wiki_spec.rb
spec/models/integrations/external_wiki_spec.rb
+3
-3
spec/models/integrations/flowdock_spec.rb
spec/models/integrations/flowdock_spec.rb
+2
-2
spec/models/integrations/pipelines_email_spec.rb
spec/models/integrations/pipelines_email_spec.rb
+2
-2
spec/models/integrations/pushover_spec.rb
spec/models/integrations/pushover_spec.rb
+2
-2
spec/models/integrations/slack_slash_commands_spec.rb
spec/models/integrations/slack_slash_commands_spec.rb
+3
-3
spec/support/shared_examples/models/chat_integration_shared_examples.rb
...hared_examples/models/chat_integration_shared_examples.rb
+1
-1
spec/support/shared_examples/models/concerns/integrations/slack_mattermost_notifier_shared_examples.rb
...integrations/slack_mattermost_notifier_shared_examples.rb
+1
-1
No files found.
doc/user/packages/container_registry/index.md
View file @
343aa7da
...
...
@@ -345,7 +345,7 @@ Below is an example of what your `.gitlab-ci.yml` should look like:
```
yaml
build
:
image
:
${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/
group/project/
docker:19.03.12
image
:
${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:19.03.12
services
:
-
name
:
${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:18.09.7-dind
alias
:
docker
...
...
doc/user/packages/dependency_proxy/index.md
View file @
343aa7da
...
...
@@ -266,7 +266,8 @@ error during connect: Get http://docker:2376/v1.39/info: dial tcp: lookup docker
This can be resolved by setting a service alias for the Docker service:
```
plaintext
```
yaml
services
:
-
name
:
${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:18.09.7-dind
alias: docker```
alias
:
docker
```
spec/models/integrations/base_issue_tracker_spec.rb
View file @
343aa7da
...
...
@@ -7,26 +7,26 @@ RSpec.describe Integrations::BaseIssueTracker do
let
(
:project
)
{
create
:project
}
describe
'only one issue tracker per project'
do
let
(
:
service
)
{
Integrations
::
Redmine
.
new
(
project:
project
,
active:
true
,
issue_tracker_data:
build
(
:issue_tracker_data
))
}
let
(
:
integration
)
{
Integrations
::
Redmine
.
new
(
project:
project
,
active:
true
,
issue_tracker_data:
build
(
:issue_tracker_data
))
}
before
do
create
(
:custom_issue_tracker_integration
,
project:
project
)
end
context
'when
service
is changed manually by user'
do
context
'when
integration
is changed manually by user'
do
it
'executes the validation'
do
valid
=
service
.
valid?
(
:manual_change
)
valid
=
integration
.
valid?
(
:manual_change
)
expect
(
valid
).
to
be_falsey
expect
(
service
.
errors
[
:base
]).
to
include
(
expect
(
integration
.
errors
[
:base
]).
to
include
(
'Another issue tracker is already in use. Only one issue tracker service can be active at a time'
)
end
end
context
'when
service
is changed internally'
do
context
'when
integration
is changed internally'
do
it
'does not execute the validation'
do
expect
(
service
.
valid?
).
to
be_truthy
expect
(
integration
.
valid?
).
to
be_truthy
end
end
end
...
...
spec/models/integrations/bugzilla_spec.rb
View file @
343aa7da
...
...
@@ -9,7 +9,7 @@ RSpec.describe Integrations::Bugzilla do
end
describe
'Validations'
do
context
'when
service
is active'
do
context
'when
integration
is active'
do
before
do
subject
.
active
=
true
end
...
...
@@ -17,12 +17,12 @@ RSpec.describe Integrations::Bugzilla do
it
{
is_expected
.
to
validate_presence_of
(
:project_url
)
}
it
{
is_expected
.
to
validate_presence_of
(
:issues_url
)
}
it
{
is_expected
.
to
validate_presence_of
(
:new_issue_url
)
}
it_behaves_like
'issue tracker
service
URL attribute'
,
:project_url
it_behaves_like
'issue tracker
service
URL attribute'
,
:issues_url
it_behaves_like
'issue tracker
service
URL attribute'
,
:new_issue_url
it_behaves_like
'issue tracker
integration
URL attribute'
,
:project_url
it_behaves_like
'issue tracker
integration
URL attribute'
,
:issues_url
it_behaves_like
'issue tracker
integration
URL attribute'
,
:new_issue_url
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
before
do
subject
.
active
=
false
end
...
...
spec/models/integrations/campfire_spec.rb
View file @
343aa7da
...
...
@@ -11,7 +11,7 @@ RSpec.describe Integrations::Campfire do
end
describe
'Validations'
do
context
'when
service
is active'
do
context
'when
integration
is active'
do
before
do
subject
.
active
=
true
end
...
...
@@ -19,7 +19,7 @@ RSpec.describe Integrations::Campfire do
it
{
is_expected
.
to
validate_presence_of
(
:token
)
}
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
before
do
subject
.
active
=
false
end
...
...
spec/models/integrations/confluence_spec.rb
View file @
343aa7da
...
...
@@ -13,7 +13,7 @@ RSpec.describe Integrations::Confluence do
subject
.
active
=
active
end
context
'when
service
is active'
do
context
'when
integration
is active'
do
let
(
:active
)
{
true
}
it
{
is_expected
.
not_to
allow_value
(
'https://example.com'
).
for
(
:confluence_url
)
}
...
...
@@ -35,7 +35,7 @@ RSpec.describe Integrations::Confluence do
it
{
is_expected
.
to
validate_presence_of
(
:confluence_url
)
}
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
let
(
:active
)
{
false
}
it
{
is_expected
.
not_to
validate_presence_of
(
:confluence_url
)
}
...
...
@@ -71,13 +71,13 @@ RSpec.describe Integrations::Confluence do
subject
{
project
.
project_setting
.
has_confluence?
}
it
'sets the property to true when
service
is active'
do
it
'sets the property to true when
integration
is active'
do
create
(
:confluence_integration
,
project:
project
,
active:
true
)
is_expected
.
to
be
(
true
)
end
it
'sets the property to false when
service
is not active'
do
it
'sets the property to false when
integration
is not active'
do
create
(
:confluence_integration
,
project:
project
,
active:
false
)
is_expected
.
to
be
(
false
)
...
...
spec/models/integrations/datadog_spec.rb
View file @
343aa7da
...
...
@@ -91,7 +91,7 @@ RSpec.describe Integrations::Datadog do
end
end
context
'when
service
is not active'
do
context
'when
integration
is not active'
do
let
(
:active
)
{
false
}
it
{
is_expected
.
to
be_valid
}
...
...
spec/models/integrations/external_wiki_spec.rb
View file @
343aa7da
...
...
@@ -9,16 +9,16 @@ RSpec.describe Integrations::ExternalWiki do
end
describe
'Validations'
do
context
'when
service
is active'
do
context
'when
integration
is active'
do
before
do
subject
.
active
=
true
end
it
{
is_expected
.
to
validate_presence_of
(
:external_wiki_url
)
}
it_behaves_like
'issue tracker
service
URL attribute'
,
:external_wiki_url
it_behaves_like
'issue tracker
integration
URL attribute'
,
:external_wiki_url
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
before
do
subject
.
active
=
false
end
...
...
spec/models/integrations/flowdock_spec.rb
View file @
343aa7da
...
...
@@ -9,7 +9,7 @@ RSpec.describe Integrations::Flowdock do
end
describe
'Validations'
do
context
'when
service
is active'
do
context
'when
integration
is active'
do
before
do
subject
.
active
=
true
end
...
...
@@ -17,7 +17,7 @@ RSpec.describe Integrations::Flowdock do
it
{
is_expected
.
to
validate_presence_of
(
:token
)
}
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
before
do
subject
.
active
=
false
end
...
...
spec/models/integrations/pipelines_email_spec.rb
View file @
343aa7da
...
...
@@ -20,7 +20,7 @@ RSpec.describe Integrations::PipelinesEmail, :mailer do
end
describe
'Validations'
do
context
'when
service
is active'
do
context
'when
integration
is active'
do
before
do
subject
.
active
=
true
end
...
...
@@ -28,7 +28,7 @@ RSpec.describe Integrations::PipelinesEmail, :mailer do
it
{
is_expected
.
to
validate_presence_of
(
:recipients
)
}
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
before
do
subject
.
active
=
false
end
...
...
spec/models/integrations/pushover_spec.rb
View file @
343aa7da
...
...
@@ -11,7 +11,7 @@ RSpec.describe Integrations::Pushover do
end
describe
'Validations'
do
context
'when
service
is active'
do
context
'when
integration
is active'
do
before
do
subject
.
active
=
true
end
...
...
@@ -21,7 +21,7 @@ RSpec.describe Integrations::Pushover do
it
{
is_expected
.
to
validate_presence_of
(
:priority
)
}
end
context
'when
service
is inactive'
do
context
'when
integration
is inactive'
do
before
do
subject
.
active
=
false
end
...
...
spec/models/integrations/slack_slash_commands_spec.rb
View file @
343aa7da
...
...
@@ -18,7 +18,7 @@ RSpec.describe Integrations::SlackSlashCommands do
}
end
let
(
:
service
)
do
let
(
:
integration
)
do
project
.
create_slack_slash_commands_integration
(
properties:
{
token:
'token'
},
active:
true
...
...
@@ -30,11 +30,11 @@ RSpec.describe Integrations::SlackSlashCommands do
end
before
do
allow
(
service
).
to
receive
(
:authorize_chat_name_url
).
and_return
(
authorize_url
)
allow
(
integration
).
to
receive
(
:authorize_chat_name_url
).
and_return
(
authorize_url
)
end
it
'uses slack compatible links'
do
response
=
service
.
trigger
(
params
)
response
=
integration
.
trigger
(
params
)
expect
(
response
[
:text
]).
to
include
(
"<
#{
authorize_url
}
|connect your GitLab account>"
)
end
...
...
spec/support/shared_examples/models/chat_integration_shared_examples.rb
View file @
343aa7da
...
...
@@ -13,7 +13,7 @@ RSpec.shared_examples "chat integration" do |integration_name|
end
it
{
is_expected
.
to
validate_presence_of
(
:webhook
)
}
it_behaves_like
"issue tracker
service
URL attribute"
,
:webhook
it_behaves_like
"issue tracker
integration
URL attribute"
,
:webhook
end
context
"when integration is inactive"
do
...
...
spec/support/shared_examples/models/concerns/integrations/slack_mattermost_notifier_shared_examples.rb
View file @
343aa7da
...
...
@@ -23,7 +23,7 @@ RSpec.shared_examples Integrations::SlackMattermostNotifier do |service_name|
end
it
{
is_expected
.
to
validate_presence_of
(
:webhook
)
}
it_behaves_like
'issue tracker
service
URL attribute'
,
:webhook
it_behaves_like
'issue tracker
integration
URL attribute'
,
:webhook
end
context
'when service is inactive'
do
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment