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
46ff3ebb
Commit
46ff3ebb
authored
Feb 09, 2022
by
Mark Lapierre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update MWPS to get more info on failure
parent
c9b14b77
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
qa/qa/page/merge_request/show.rb
qa/qa/page/merge_request/show.rb
+2
-1
qa/qa/specs/features/browser_ui/3_create/merge_request/merge_when_pipeline_succeeds_spec.rb
...create/merge_request/merge_when_pipeline_succeeds_spec.rb
+4
-2
No files found.
qa/qa/page/merge_request/show.rb
View file @
46ff3ebb
...
@@ -263,7 +263,8 @@ module QA
...
@@ -263,7 +263,8 @@ module QA
# status as unmerged, the test will fail.
# status as unmerged, the test will fail.
# Revisit after merge page re-architect is done https://gitlab.com/groups/gitlab-org/-/epics/5598
# Revisit after merge page re-architect is done https://gitlab.com/groups/gitlab-org/-/epics/5598
# To remove page refresh logic if possible
# To remove page refresh logic if possible
retry_until
(
max_attempts:
3
,
reload:
true
)
do
# We don't raise on failure because this method is used as a predicate matcher
retry_until
(
max_attempts:
3
,
reload:
true
,
raise_on_failure:
false
)
do
has_element?
(
:merged_status_content
,
text:
'The changes were merged into'
,
wait:
20
)
has_element?
(
:merged_status_content
,
text:
'The changes were merged into'
,
wait:
20
)
end
end
end
end
...
...
qa/qa/specs/features/browser_ui/3_create/merge_request/merge_when_pipeline_succeeds_spec.rb
View file @
46ff3ebb
...
@@ -88,7 +88,7 @@ module QA
...
@@ -88,7 +88,7 @@ module QA
mr
.
wait_until_ready_to_merge
(
transient_test:
transient_test
)
mr
.
wait_until_ready_to_merge
(
transient_test:
transient_test
)
mr
.
retry_until
(
reload:
true
,
message:
'Wait until ready to click MWPS'
)
do
mr
.
retry_until
(
reload:
true
,
message:
'Wait until ready to click MWPS'
)
do
merge_request
=
merge_request
.
reload!
merge_request
.
reload!
# Don't try to click MWPS if the MR is merged or the pipeline is complete
# Don't try to click MWPS if the MR is merged or the pipeline is complete
break
if
merge_request
.
state
==
'merged'
||
mr
.
wait_until
{
project
.
pipelines
.
last
}[
:status
]
==
'success'
break
if
merge_request
.
state
==
'merged'
||
mr
.
wait_until
{
project
.
pipelines
.
last
}[
:status
]
==
'success'
...
@@ -102,8 +102,10 @@ module QA
...
@@ -102,8 +102,10 @@ module QA
end
end
aggregate_failures
do
aggregate_failures
do
expect
(
mr
.
merged?
).
to
be_truthy
,
"Expected content 'The changes were merged' but it did not appear."
expect
{
mr
.
merged?
}.
to
eventually_be_truthy
.
within
(
max_duration:
60
)
,
"Expected content 'The changes were merged' but it did not appear."
expect
(
merge_request
.
reload!
.
merge_when_pipeline_succeeds
).
to
be_truthy
expect
(
merge_request
.
reload!
.
merge_when_pipeline_succeeds
).
to
be_truthy
expect
(
merge_request
.
state
).
to
eq
(
'merged'
)
expect
(
project
.
pipelines
.
last
[
:status
]).
to
eq
(
'success'
)
end
end
end
end
end
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