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
22e1476d
Commit
22e1476d
authored
Apr 05, 2021
by
Tomislav Nikić
Committed by
Sanad Liaquat
Apr 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reverting a merge request E2E test
parent
3821a02c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
46 additions
and
0 deletions
+46
-0
app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_merged.vue
...rge_request_widget/components/states/mr_widget_merged.vue
+1
-0
qa/qa/page/merge_request/show.rb
qa/qa/page/merge_request/show.rb
+6
-0
qa/qa/specs/features/browser_ui/3_create/merge_request/revert_spec.rb
...features/browser_ui/3_create/merge_request/revert_spec.rb
+39
-0
No files found.
app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_merged.vue
View file @
22e1476d
...
...
@@ -130,6 +130,7 @@ export default {
size=
"small"
category=
"secondary"
variant=
"warning"
data-qa-selector=
"revert_button"
@
click=
"openRevertModal"
>
{{
revertLabel
}}
...
...
qa/qa/page/merge_request/show.rb
View file @
22e1476d
...
...
@@ -108,6 +108,7 @@ module QA
end
view
'app/assets/javascripts/vue_merge_request_widget/components/states/mr_widget_merged.vue'
do
element
:revert_button
element
:cherry_pick_button
end
...
...
@@ -368,6 +369,11 @@ module QA
click_element
(
:cherry_pick_button
,
Page
::
Component
::
CommitModal
)
click_element
(
:submit_commit_button
)
end
def
revert_change!
click_element
(
:revert_button
,
Page
::
Component
::
CommitModal
)
click_element
(
:submit_commit_button
)
end
end
end
end
...
...
qa/qa/specs/features/browser_ui/3_create/merge_request/revert_spec.rb
0 → 100644
View file @
22e1476d
# frozen_string_literal: true
module
QA
RSpec
.
describe
'Create'
do
describe
'Merged merge request'
do
let
(
:project
)
do
Resource
::
Project
.
fabricate_via_api!
do
|
project
|
project
.
name
=
'revert'
end
end
let
(
:revertable_merge_request
)
do
Resource
::
MergeRequest
.
fabricate_via_api!
do
|
merge_request
|
merge_request
.
project
=
project
end
end
before
do
Flow
::
Login
.
sign_in
end
it
'can be reverted'
,
testcase:
'https://gitlab.com/gitlab-org/quality/testcases/-/issues/1745'
do
revertable_merge_request
.
visit!
Page
::
MergeRequest
::
Show
.
perform
do
|
merge_request
|
merge_request
.
merge!
merge_request
.
revert_change!
end
Page
::
MergeRequest
::
New
.
perform
(
&
:create_merge_request
)
Page
::
MergeRequest
::
Show
.
perform
do
|
merge_request
|
merge_request
.
click_diffs_tab
expect
(
merge_request
).
to
have_file
(
revertable_merge_request
.
file_name
)
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