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
36f63389
Commit
36f63389
authored
Jul 08, 2020
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve the en/dis-ablement of the design mgt feature in a flaky test
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
0f68786a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
24 deletions
+18
-24
spec/features/projects/issues/design_management/user_uploads_designs_spec.rb
...cts/issues/design_management/user_uploads_designs_spec.rb
+18
-24
No files found.
spec/features/projects/issues/design_management/user_uploads_designs_spec.rb
View file @
36f63389
...
...
@@ -14,17 +14,18 @@ RSpec.describe 'User uploads new design', :js do
end
context
'design_management_moved flag disabled'
do
context
"when the feature is available"
do
before
do
enable_design_management
stub_feature_flags
(
design_management_moved:
fals
e
)
before
do
enable_design_management
(
feature_enabled
)
stub_feature_flags
(
design_management_moved:
false
)
visit
project_issue_path
(
project
,
issu
e
)
visit
project_issue_path
(
project
,
issue
)
click_link
'Designs'
click_link
'Designs'
wait_for_requests
end
wait_for_requests
end
context
"when the feature is available"
do
let
(
:feature_enabled
)
{
true
}
it
'uploads designs'
do
attach_file
(
:design_file
,
logo_fixture
,
make_visible:
true
)
...
...
@@ -42,14 +43,7 @@ RSpec.describe 'User uploads new design', :js do
end
context
'when the feature is not available'
do
before
do
stub_feature_flags
(
design_management_moved:
false
)
visit
project_issue_path
(
project
,
issue
)
click_link
'Designs'
wait_for_requests
end
let
(
:feature_enabled
)
{
false
}
it
'shows the message about requirements'
do
expect
(
page
).
to
have_content
(
"To enable design management, you'll need to meet the requirements."
)
...
...
@@ -58,12 +52,14 @@ RSpec.describe 'User uploads new design', :js do
end
context
'design_management_moved flag enabled'
do
context
"when the feature is available"
do
before
do
enable_design_management
before
do
enable_design_management
(
feature_enabled
)
stub_feature_flags
(
design_management_moved:
true
)
visit
project_issue_path
(
project
,
issue
)
end
visit
project_issue_path
(
project
,
issue
)
end
context
"when the feature is available"
do
let
(
:feature_enabled
)
{
true
}
it
'uploads designs'
,
quarantine:
'https://gitlab.com/gitlab-org/gitlab/-/issues/225616'
do
attach_file
(
:design_file
,
logo_fixture
,
make_visible:
true
)
...
...
@@ -81,9 +77,7 @@ RSpec.describe 'User uploads new design', :js do
end
context
'when the feature is not available'
do
before
do
visit
project_issue_path
(
project
,
issue
)
end
let
(
:feature_enabled
)
{
false
}
it
'shows the message about requirements'
do
expect
(
page
).
to
have_content
(
"To enable design management, you'll need to meet the requirements."
)
...
...
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