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
cc95525c
Commit
cc95525c
authored
Jul 07, 2021
by
Andrejs Cunskis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move feature flag toggle to before-each block
parent
4e20c48e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
14 deletions
+8
-14
qa/qa/specs/features/browser_ui/1_manage/group/bulk_import_group_spec.rb
...tures/browser_ui/1_manage/group/bulk_import_group_spec.rb
+8
-14
No files found.
qa/qa/specs/features/browser_ui/1_manage/group/bulk_import_group_spec.rb
View file @
cc95525c
...
...
@@ -3,16 +3,18 @@
module
QA
RSpec
.
describe
'Manage'
,
:requires_admin
do
describe
'Bulk group import'
do
let!
(
:admin_api_client
)
{
Runtime
::
API
::
Client
.
as_admin
}
let!
(
:user
)
do
let!
(
:staging?
)
{
Runtime
::
Scenario
.
gitlab_address
.
include?
(
'staging.gitlab.com'
)
}
let
(
:admin_api_client
)
{
Runtime
::
API
::
Client
.
as_admin
}
let
(
:user
)
do
Resource
::
User
.
fabricate_via_api!
do
|
usr
|
usr
.
api_client
=
admin_api_client
usr
.
hard_delete_on_api_removal
=
true
end
end
let
!
(
:api_client
)
{
Runtime
::
API
::
Client
.
new
(
user:
user
)
}
let
!
(
:personal_access_token
)
{
api_client
.
personal_access_token
}
let
(
:api_client
)
{
Runtime
::
API
::
Client
.
new
(
user:
user
)
}
let
(
:personal_access_token
)
{
api_client
.
personal_access_token
}
let
(
:sandbox
)
do
Resource
::
Sandbox
.
fabricate_via_api!
do
|
group
|
...
...
@@ -51,16 +53,10 @@ module QA
end
end
def
staging?
Runtime
::
Scenario
.
gitlab_address
.
include?
(
'staging.gitlab.com'
)
end
before
(
:all
)
do
before
do
Runtime
::
Feature
.
enable
(
:bulk_import
)
unless
staging?
Runtime
::
Feature
.
enable
(
:top_level_group_creation_enabled
)
if
staging?
end
before
do
sandbox
.
add_member
(
user
,
Resource
::
Members
::
AccessLevel
::
MAINTAINER
)
# create groups explicitly before connecting gitlab instance
...
...
@@ -116,9 +112,7 @@ module QA
after
do
user
.
remove_via_api!
end
after
(
:all
)
do
ensure
Runtime
::
Feature
.
disable
(
:bulk_import
)
unless
staging?
Runtime
::
Feature
.
disable
(
:top_level_group_creation_enabled
)
if
staging?
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