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
11d94d9e
Commit
11d94d9e
authored
Mar 21, 2022
by
John McDonnell
Committed by
Anastasia McDonald
Mar 21, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Dequarantine jenkins_build_status_spec E2E
parent
8b37e510
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
16 additions
and
11 deletions
+16
-11
qa/qa/page/project/settings/services/jenkins.rb
qa/qa/page/project/settings/services/jenkins.rb
+8
-8
qa/qa/specs/features/browser_ui/3_create/jenkins/jenkins_build_status_spec.rb
.../browser_ui/3_create/jenkins/jenkins_build_status_spec.rb
+2
-2
qa/qa/support/page_error_checker.rb
qa/qa/support/page_error_checker.rb
+1
-1
qa/qa/vendor/jenkins/page/configure_job.rb
qa/qa/vendor/jenkins/page/configure_job.rb
+5
-0
No files found.
qa/qa/page/project/settings/services/jenkins.rb
View file @
11d94d9e
...
...
@@ -7,10 +7,10 @@ module QA
module
Services
class
Jenkins
<
QA
::
Page
::
Base
view
'app/assets/javascripts/integrations/edit/components/dynamic_field.vue'
do
element
:jenkins_url_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:project_name_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:username_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:password_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:
service_
jenkins_url_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:
service_
project_name_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:
service_
username_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
element
:
service_
password_field
,
':data-qa-selector="`${fieldId}_field`"'
# rubocop:disable QA/ElementWithPattern
end
view
'app/assets/javascripts/integrations/edit/components/integration_form.vue'
do
...
...
@@ -28,19 +28,19 @@ module QA
private
def
set_jenkins_url
(
jenkins_url
)
fill_element
(
:jenkins_url_field
,
jenkins_url
)
fill_element
(
:
service_
jenkins_url_field
,
jenkins_url
)
end
def
set_project_name
(
project_name
)
fill_element
(
:project_name_field
,
project_name
)
fill_element
(
:
service_
project_name_field
,
project_name
)
end
def
set_username
(
username
)
fill_element
(
:username_field
,
username
)
fill_element
(
:
service_
username_field
,
username
)
end
def
set_password
(
password
)
fill_element
(
:password_field
,
password
)
fill_element
(
:
service_
password_field
,
password
)
end
def
click_save_changes_button
...
...
qa/qa/specs/features/browser_ui/3_create/jenkins/jenkins_build_status_spec.rb
View file @
11d94d9e
# frozen_string_literal: true
module
QA
RSpec
.
describe
'Create'
,
:requires_admin
,
:skip_live_env
,
quarantine:
{
issue:
'https://gitlab.com/gitlab-org/gitlab/-/issues/195179'
,
type: :flaky
}
do
RSpec
.
describe
'Create'
,
:requires_admin
,
:skip_live_env
do
describe
'Jenkins integration'
do
let
(
:project_name
)
{
"project_with_jenkins_
#{
SecureRandom
.
hex
(
4
)
}
"
}
...
...
@@ -30,7 +30,7 @@ module QA
setup_project_integration_with_jenkins
expect
(
page
).
to
have_text
(
"Jenkins
CI activated
."
)
expect
(
page
).
to
have_text
(
"Jenkins
settings saved and active
."
)
QA
::
Support
::
Retrier
.
retry_on_exception
do
Resource
::
Repository
::
ProjectPush
.
fabricate!
do
|
push
|
...
...
qa/qa/support/page_error_checker.rb
View file @
11d94d9e
...
...
@@ -49,7 +49,7 @@ module QA
error_code
=
404
if
Nokogiri
::
HTML
.
parse
(
page
.
html
).
xpath
(
"//img"
).
map
{
|
t
|
t
[
:alt
]
}.
first
.
eql?
(
'404'
)
# 500 error page in header surrounded by newlines, try to match
five_hundred_test
=
Nokogiri
::
HTML
.
parse
(
page
.
html
).
xpath
(
"//h1"
).
map
.
first
five_hundred_test
=
Nokogiri
::
HTML
.
parse
(
page
.
html
).
xpath
(
"//h1
/text()
"
).
map
.
first
unless
five_hundred_test
.
nil?
error_code
=
500
if
five_hundred_test
.
text
.
include?
(
'500'
)
end
...
...
qa/qa/vendor/jenkins/page/configure_job.rb
View file @
11d94d9e
...
...
@@ -15,6 +15,7 @@ module QA
def
configure
(
scm_url
:)
set_git_source_code_management_url
(
scm_url
)
set_git_branches_to_build
(
"*/
#{
Runtime
::
Env
.
default_branch
}
"
)
click_build_when_change_is_pushed_to_gitlab
set_publish_status_to_gitlab
...
...
@@ -31,6 +32,10 @@ module QA
set_repository_url
(
repository_url
)
end
def
set_git_branches_to_build
(
branches
)
find
(
'.setting-name'
,
text:
"Branch Specifier (blank for 'any')"
).
find
(
:xpath
,
".."
).
find
(
'input'
).
set
branches
end
def
click_build_when_change_is_pushed_to_gitlab
find
(
'label'
,
text:
'Build when a change is pushed to GitLab'
).
find
(
:xpath
,
".."
).
find
(
'input'
).
click
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