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
320e2fe8
Commit
320e2fe8
authored
Feb 17, 2022
by
Justin Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix copy changes in specs
parent
73c83398
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
13 deletions
+4
-13
spec/features/projects/integrations/user_activates_jetbrains_teamcity_ci_spec.rb
...integrations/user_activates_jetbrains_teamcity_ci_spec.rb
+1
-1
spec/serializers/service_event_entity_spec.rb
spec/serializers/service_event_entity_spec.rb
+2
-2
spec/support/shared_examples/integrations/integration_settings_form.rb
...shared_examples/integrations/integration_settings_form.rb
+1
-10
No files found.
spec/features/projects/integrations/user_activates_jetbrains_teamcity_ci_spec.rb
View file @
320e2fe8
...
...
@@ -12,7 +12,7 @@ RSpec.describe 'User activates JetBrains TeamCity CI' do
it
'activates integration'
,
:js
do
visit_project_integration
(
'JetBrains TeamCity'
)
check
(
'Push'
)
check
(
'Merge
R
equest'
)
check
(
'Merge
r
equest'
)
fill_in
(
'TeamCity server URL'
,
with:
'http://teamcity.example.com'
)
fill_in
(
'Build type'
,
with:
'GitlabTest_Build'
)
fill_in
(
'Username'
,
with:
'user'
)
...
...
spec/serializers/service_event_entity_spec.rb
View file @
320e2fe8
...
...
@@ -19,7 +19,7 @@ RSpec.describe ServiceEventEntity do
it
'exposes correct attributes'
do
expect
(
subject
[
:description
]).
to
eq
(
'Trigger event for pushes to the repository.'
)
expect
(
subject
[
:name
]).
to
eq
(
'push_events'
)
expect
(
subject
[
:title
]).
to
eq
(
'
p
ush'
)
expect
(
subject
[
:title
]).
to
eq
(
'
P
ush'
)
expect
(
subject
[
:value
]).
to
be
(
true
)
end
end
...
...
@@ -31,7 +31,7 @@ RSpec.describe ServiceEventEntity do
it
'exposes correct attributes'
do
expect
(
subject
[
:description
]).
to
eq
(
'Trigger event for new comments.'
)
expect
(
subject
[
:name
]).
to
eq
(
'note_events'
)
expect
(
subject
[
:title
]).
to
eq
(
'
n
ote'
)
expect
(
subject
[
:title
]).
to
eq
(
'
N
ote'
)
expect
(
subject
[
:value
]).
to
eq
(
false
)
expect
(
subject
[
:field
][
:name
]).
to
eq
(
'note_channel'
)
expect
(
subject
[
:field
][
:value
]).
to
eq
(
'note-channel'
)
...
...
spec/support/shared_examples/integrations/integration_settings_form.rb
View file @
320e2fe8
...
...
@@ -22,10 +22,7 @@ RSpec.shared_examples 'integration settings form' do
events
=
parse_json
(
trigger_events_for_integration
(
integration
))
events
.
each
do
|
trigger
|
# normalizing the title because capybara location is case sensitive
title
=
normalize_title
trigger
[
:title
],
integration
expect
(
page
).
to
have_field
(
title
,
type:
'checkbox'
,
wait:
0
),
expect
(
page
).
to
have_field
(
trigger
[
:title
],
type:
'checkbox'
,
wait:
0
),
"
#{
integration
.
title
}
field
#{
title
}
checkbox not present"
end
end
...
...
@@ -35,12 +32,6 @@ RSpec.shared_examples 'integration settings form' do
private
def
normalize_title
(
title
,
integration
)
return
'Merge request'
if
integration
.
is_a?
(
Integrations
::
Jira
)
&&
title
==
'merge_request'
title
.
titlecase
end
def
parse_json
(
json
)
Gitlab
::
Json
.
parse
(
json
,
symbolize_names:
true
)
end
...
...
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