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
c027920b
Commit
c027920b
authored
Jan 26, 2022
by
charlie ablett
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replace owner with first_owner in EE spec fixtures
parent
99be341f
Changes
27
Hide whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
46 additions
and
42 deletions
+46
-42
ee/spec/controllers/autocomplete_controller_spec.rb
ee/spec/controllers/autocomplete_controller_spec.rb
+1
-1
ee/spec/controllers/projects/branches_controller_spec.rb
ee/spec/controllers/projects/branches_controller_spec.rb
+1
-1
ee/spec/controllers/projects/merge_requests/creations_controller_spec.rb
...lers/projects/merge_requests/creations_controller_spec.rb
+1
-1
ee/spec/controllers/projects/mirrors_controller_spec.rb
ee/spec/controllers/projects/mirrors_controller_spec.rb
+16
-12
ee/spec/controllers/projects/path_locks_controller_spec.rb
ee/spec/controllers/projects/path_locks_controller_spec.rb
+1
-1
ee/spec/controllers/projects_controller_spec.rb
ee/spec/controllers/projects_controller_spec.rb
+1
-1
ee/spec/elastic_integration/repository_index_spec.rb
ee/spec/elastic_integration/repository_index_spec.rb
+1
-1
ee/spec/features/ide/user_commits_changes_spec.rb
ee/spec/features/ide/user_commits_changes_spec.rb
+1
-1
ee/spec/features/ide/user_opens_ide_spec.rb
ee/spec/features/ide/user_opens_ide_spec.rb
+1
-1
ee/spec/features/merge_request/user_creates_merge_request_with_blocking_mrs_spec.rb
...uest/user_creates_merge_request_with_blocking_mrs_spec.rb
+1
-1
ee/spec/features/merge_request/user_edits_merge_request_blocking_mrs_spec.rb
...rge_request/user_edits_merge_request_blocking_mrs_spec.rb
+1
-1
ee/spec/features/merge_trains/two_merge_requests_on_train_spec.rb
...features/merge_trains/two_merge_requests_on_train_spec.rb
+1
-1
ee/spec/features/projects/active_tabs_spec.rb
ee/spec/features/projects/active_tabs_spec.rb
+1
-1
ee/spec/features/projects/audit_events_spec.rb
ee/spec/features/projects/audit_events_spec.rb
+2
-2
ee/spec/features/projects/kerberos_clone_instructions_spec.rb
...pec/features/projects/kerberos_clone_instructions_spec.rb
+1
-1
ee/spec/features/projects/navbar_spec.rb
ee/spec/features/projects/navbar_spec.rb
+1
-1
ee/spec/features/projects/settings/user_manages_approval_settings_spec.rb
.../projects/settings/user_manages_approval_settings_spec.rb
+1
-1
ee/spec/features/projects/view_blob_with_code_owners_spec.rb
ee/spec/features/projects/view_blob_with_code_owners_spec.rb
+1
-1
ee/spec/features/projects_spec.rb
ee/spec/features/projects_spec.rb
+1
-1
ee/spec/features/protected_branches_spec.rb
ee/spec/features/protected_branches_spec.rb
+1
-1
ee/spec/features/protected_tags_spec.rb
ee/spec/features/protected_tags_spec.rb
+1
-1
ee/spec/features/security/project/snippet/internal_access_spec.rb
...features/security/project/snippet/internal_access_spec.rb
+2
-2
ee/spec/features/security/project/snippet/private_access_spec.rb
.../features/security/project/snippet/private_access_spec.rb
+1
-1
ee/spec/features/security/project/snippet/public_access_spec.rb
...c/features/security/project/snippet/public_access_spec.rb
+3
-3
ee/spec/finders/productivity_analytics_finder_spec.rb
ee/spec/finders/productivity_analytics_finder_spec.rb
+1
-1
ee/spec/frontend/fixtures/merge_requests.rb
ee/spec/frontend/fixtures/merge_requests.rb
+1
-1
ee/spec/frontend/fixtures/projects.rb
ee/spec/frontend/fixtures/projects.rb
+1
-1
No files found.
ee/spec/controllers/autocomplete_controller_spec.rb
View file @
c027920b
...
@@ -142,7 +142,7 @@ RSpec.describe AutocompleteController do
...
@@ -142,7 +142,7 @@ RSpec.describe AutocompleteController do
end
end
context
'as project owner'
do
context
'as project owner'
do
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
let!
(
:expected_results
)
{
[[
project
.
id
,
'Project'
]]
}
let!
(
:expected_results
)
{
[[
project
.
id
,
'Project'
]]
}
context
"while searching for a project by namespace"
do
context
"while searching for a project by namespace"
do
...
...
ee/spec/controllers/projects/branches_controller_spec.rb
View file @
c027920b
...
@@ -5,7 +5,7 @@ require 'spec_helper'
...
@@ -5,7 +5,7 @@ require 'spec_helper'
RSpec
.
describe
Projects
::
BranchesController
do
RSpec
.
describe
Projects
::
BranchesController
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
allow
(
project
).
to
receive
(
:branches
).
and_return
([
'master'
])
allow
(
project
).
to
receive
(
:branches
).
and_return
([
'master'
])
...
...
ee/spec/controllers/projects/merge_requests/creations_controller_spec.rb
View file @
c027920b
...
@@ -5,7 +5,7 @@ require 'spec_helper'
...
@@ -5,7 +5,7 @@ require 'spec_helper'
RSpec
.
describe
Projects
::
MergeRequests
::
CreationsController
do
RSpec
.
describe
Projects
::
MergeRequests
::
CreationsController
do
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:merge_request
)
{
create
(
:merge_request_with_diffs
,
target_project:
project
,
source_project:
project
)
}
let
(
:merge_request
)
{
create
(
:merge_request_with_diffs
,
target_project:
project
,
source_project:
project
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
let
(
:viewer
)
{
user
}
let
(
:viewer
)
{
user
}
before
do
before
do
...
...
ee/spec/controllers/projects/mirrors_controller_spec.rb
View file @
c027920b
...
@@ -7,14 +7,16 @@ RSpec.describe Projects::MirrorsController do
...
@@ -7,14 +7,16 @@ RSpec.describe Projects::MirrorsController do
describe
'setting up a remote mirror'
do
describe
'setting up a remote mirror'
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:first_owner
)
{
project
.
first_owner
}
let
(
:url
)
{
'http://foo.com'
}
let
(
:url
)
{
'http://foo.com'
}
context
'when the current project is a mirror'
do
context
'when the current project is a mirror'
do
let
(
:project
)
{
create
(
:project
,
:repository
,
:mirror
)
}
let
(
:project
)
{
create
(
:project
,
:repository
,
:mirror
)
}
let
(
:first_owner
)
{
project
.
first_owner
}
before
do
before
do
sign_in
(
project
.
owner
)
sign_in
(
first_
owner
)
end
end
it
'allows to create a remote mirror'
do
it
'allows to create a remote mirror'
do
...
@@ -28,7 +30,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -28,7 +30,7 @@ RSpec.describe Projects::MirrorsController do
let
(
:remote_mirror
)
{
project
.
remote_mirrors
.
create!
(
enabled:
1
,
url:
'http://local.dev'
)
}
let
(
:remote_mirror
)
{
project
.
remote_mirrors
.
create!
(
enabled:
1
,
url:
'http://local.dev'
)
}
before
do
before
do
sign_in
(
project
.
owner
)
sign_in
(
first_
owner
)
end
end
context
'mirror_user is unset'
do
context
'mirror_user is unset'
do
...
@@ -40,7 +42,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -40,7 +42,7 @@ RSpec.describe Projects::MirrorsController do
expect
(
project
.
mirror
).
to
eq
(
true
)
expect
(
project
.
mirror
).
to
eq
(
true
)
expect
(
project
.
import_url
).
to
eq
(
'http://local.dev'
)
expect
(
project
.
import_url
).
to
eq
(
'http://local.dev'
)
expect
(
project
.
mirror_user
).
to
eq
(
project
.
owner
)
expect
(
project
.
mirror_user
).
to
eq
(
first_
owner
)
end
end
end
end
...
@@ -53,7 +55,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -53,7 +55,7 @@ RSpec.describe Projects::MirrorsController do
expect
(
project
.
mirror
).
to
eq
(
true
)
expect
(
project
.
mirror
).
to
eq
(
true
)
expect
(
project
.
import_url
).
to
eq
(
'http://local.dev'
)
expect
(
project
.
import_url
).
to
eq
(
'http://local.dev'
)
expect
(
project
.
mirror_user
).
to
eq
(
project
.
owner
)
expect
(
project
.
mirror_user
).
to
eq
(
first_
owner
)
end
end
end
end
end
end
...
@@ -62,6 +64,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -62,6 +64,7 @@ RSpec.describe Projects::MirrorsController do
describe
'setting up a mirror'
do
describe
'setting up a mirror'
do
let
(
:url
)
{
'http://foo.com'
}
let
(
:url
)
{
'http://foo.com'
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:first_owner
)
{
project
.
first_owner
}
context
'when mirrors are disabled'
do
context
'when mirrors are disabled'
do
before
do
before
do
...
@@ -82,7 +85,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -82,7 +85,7 @@ RSpec.describe Projects::MirrorsController do
context
'when user is not an admin'
do
context
'when user is not an admin'
do
it
'does not create a new mirror'
do
it
'does not create a new mirror'
do
sign_in
(
project
.
owner
)
sign_in
(
first_
owner
)
expect
do
expect
do
do_put
(
project
,
mirror:
true
,
import_url:
url
)
do_put
(
project
,
mirror:
true
,
import_url:
url
)
...
@@ -93,13 +96,13 @@ RSpec.describe Projects::MirrorsController do
...
@@ -93,13 +96,13 @@ RSpec.describe Projects::MirrorsController do
context
'when mirrors are enabled'
do
context
'when mirrors are enabled'
do
before
do
before
do
sign_in
(
project
.
owner
)
sign_in
(
first_
owner
)
end
end
context
'when project does not have a mirror'
do
context
'when project does not have a mirror'
do
it
'allows to create a mirror'
do
it
'allows to create a mirror'
do
expect
do
expect
do
do_put
(
project
,
mirror:
true
,
mirror_user_id:
project
.
owner
.
id
,
import_url:
url
)
do_put
(
project
,
mirror:
true
,
mirror_user_id:
first_
owner
.
id
,
import_url:
url
)
end
.
to
change
{
Project
.
mirror
.
count
}.
to
(
1
)
end
.
to
change
{
Project
.
mirror
.
count
}.
to
(
1
)
end
end
end
end
...
@@ -117,7 +120,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -117,7 +120,7 @@ RSpec.describe Projects::MirrorsController do
describe
'forcing an update on a pull mirror'
do
describe
'forcing an update on a pull mirror'
do
it
'forces update'
do
it
'forces update'
do
project
=
create
(
:project
,
:mirror
)
project
=
create
(
:project
,
:mirror
)
sign_in
(
project
.
owner
)
sign_in
(
project
.
first_
owner
)
Sidekiq
::
Testing
.
fake!
do
Sidekiq
::
Testing
.
fake!
do
expect
{
put
:update_now
,
params:
{
namespace_id:
project
.
namespace
.
to_param
,
project_id:
project
.
to_param
}
}
expect
{
put
:update_now
,
params:
{
namespace_id:
project
.
namespace
.
to_param
,
project_id:
project
.
to_param
}
}
...
@@ -129,10 +132,11 @@ RSpec.describe Projects::MirrorsController do
...
@@ -129,10 +132,11 @@ RSpec.describe Projects::MirrorsController do
describe
'#update'
do
describe
'#update'
do
let
(
:project
)
{
create
(
:project
,
:repository
,
:mirror
,
:remote_mirror
)
}
let
(
:project
)
{
create
(
:project
,
:repository
,
:mirror
,
:remote_mirror
)
}
let
(
:attributes
)
{
{
project:
{
mirror_user_id:
project
.
owner
.
id
,
mirror_trigger_builds:
0
},
namespace_id:
project
.
namespace
.
to_param
,
project_id:
project
.
to_param
}
}
let
(
:first_owner
)
{
project
.
first_owner
}
let
(
:attributes
)
{
{
project:
{
mirror_user_id:
first_owner
.
id
,
mirror_trigger_builds:
0
},
namespace_id:
project
.
namespace
.
to_param
,
project_id:
project
.
to_param
}
}
before
do
before
do
sign_in
(
project
.
owner
)
sign_in
(
first_
owner
)
end
end
around
do
|
example
|
around
do
|
example
|
...
@@ -170,7 +174,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -170,7 +174,7 @@ RSpec.describe Projects::MirrorsController do
import_data
=
project
.
reload_import_data
import_data
=
project
.
reload_import_data
expect
(
import_data
.
ssh_known_hosts_verified_at
).
to
be_within
(
1
.
minute
).
of
(
Time
.
current
)
expect
(
import_data
.
ssh_known_hosts_verified_at
).
to
be_within
(
1
.
minute
).
of
(
Time
.
current
)
expect
(
import_data
.
ssh_known_hosts_verified_by
).
to
eq
(
project
.
owner
)
expect
(
import_data
.
ssh_known_hosts_verified_by
).
to
eq
(
first_
owner
)
end
end
it
'unsets ssh_known_hosts_verified_at and verified_by when the update unsets known hosts'
do
it
'unsets ssh_known_hosts_verified_at and verified_by when the update unsets known hosts'
do
...
@@ -191,7 +195,7 @@ RSpec.describe Projects::MirrorsController do
...
@@ -191,7 +195,7 @@ RSpec.describe Projects::MirrorsController do
do_put
(
project
,
{
mirror_user_id:
other_user
.
id
},
format: :json
)
do_put
(
project
,
{
mirror_user_id:
other_user
.
id
},
format: :json
)
expect
(
project
.
reload
.
mirror_user
).
to
eq
(
project
.
owner
)
expect
(
project
.
reload
.
mirror_user
).
to
eq
(
first_
owner
)
end
end
end
end
...
...
ee/spec/controllers/projects/path_locks_controller_spec.rb
View file @
c027920b
...
@@ -4,7 +4,7 @@ require 'spec_helper'
...
@@ -4,7 +4,7 @@ require 'spec_helper'
RSpec
.
describe
Projects
::
PathLocksController
do
RSpec
.
describe
Projects
::
PathLocksController
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
,
:public
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
,
:public
)
}
let_it_be
(
:user
)
{
project
.
owner
}
let_it_be
(
:user
)
{
project
.
first_
owner
}
let
(
:file_path
)
{
'files/lfs/lfs_object.iso'
}
let
(
:file_path
)
{
'files/lfs/lfs_object.iso'
}
let
(
:lfs_enabled
)
{
true
}
let
(
:lfs_enabled
)
{
true
}
...
...
ee/spec/controllers/projects_controller_spec.rb
View file @
c027920b
...
@@ -561,7 +561,7 @@ RSpec.describe ProjectsController do
...
@@ -561,7 +561,7 @@ RSpec.describe ProjectsController do
context
'current_user is a project owner'
do
context
'current_user is a project owner'
do
before
do
before
do
sign_in
(
project
.
owner
)
sign_in
(
project
.
first_
owner
)
end
end
it
'sets the compliance framework'
do
it
'sets the compliance framework'
do
...
...
ee/spec/elastic_integration/repository_index_spec.rb
View file @
c027920b
...
@@ -5,7 +5,7 @@ require 'spec_helper'
...
@@ -5,7 +5,7 @@ require 'spec_helper'
RSpec
.
describe
'Repository index'
,
:elastic
,
:clean_gitlab_redis_shared_state
do
RSpec
.
describe
'Repository index'
,
:elastic
,
:clean_gitlab_redis_shared_state
do
context
'when fresh master branch is first pushed, followed by another update, then indexed'
do
context
'when fresh master branch is first pushed, followed by another update, then indexed'
do
let
(
:project
)
{
create
(
:project_empty_repo
)
}
let
(
:project
)
{
create
(
:project_empty_repo
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
stub_ee_application_setting
(
elasticsearch_search:
true
,
elasticsearch_indexing:
true
)
stub_ee_application_setting
(
elasticsearch_search:
true
,
elasticsearch_indexing:
true
)
...
...
ee/spec/features/ide/user_commits_changes_spec.rb
View file @
c027920b
...
@@ -7,7 +7,7 @@ RSpec.describe 'EE IDE user commits changes', :js do
...
@@ -7,7 +7,7 @@ RSpec.describe 'EE IDE user commits changes', :js do
let
(
:project
)
{
create
(
:project
,
:custom_repo
,
files:
{
'docs/CODEOWNERS'
=>
"[Backend]
\n
*.rb @ruby-owner"
})
}
let
(
:project
)
{
create
(
:project
,
:custom_repo
,
files:
{
'docs/CODEOWNERS'
=>
"[Backend]
\n
*.rb @ruby-owner"
})
}
let
(
:ruby_owner
)
{
create
(
:user
,
username:
'ruby-owner'
)
}
let
(
:ruby_owner
)
{
create
(
:user
,
username:
'ruby-owner'
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
stub_licensed_features
(
code_owners:
true
,
code_owner_approval_required:
true
)
stub_licensed_features
(
code_owners:
true
,
code_owner_approval_required:
true
)
...
...
ee/spec/features/ide/user_opens_ide_spec.rb
View file @
c027920b
...
@@ -9,7 +9,7 @@ RSpec.describe 'EE user opens IDE', :js do
...
@@ -9,7 +9,7 @@ RSpec.describe 'EE user opens IDE', :js do
let_it_be
(
:unsigned_commits_warning
)
{
'This project does not accept unsigned commits.'
}
let_it_be
(
:unsigned_commits_warning
)
{
'This project does not accept unsigned commits.'
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
stub_licensed_features
(
push_rules:
true
)
stub_licensed_features
(
push_rules:
true
)
...
...
ee/spec/features/merge_request/user_creates_merge_request_with_blocking_mrs_spec.rb
View file @
c027920b
...
@@ -4,7 +4,7 @@ require 'spec_helper'
...
@@ -4,7 +4,7 @@ require 'spec_helper'
RSpec
.
describe
'User creates a merge request with blocking MRs'
,
:js
do
RSpec
.
describe
'User creates a merge request with blocking MRs'
,
:js
do
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
let
(
:mr_params
)
{
{
title:
'Some feature'
,
source_branch:
'fix'
,
target_branch:
'feature'
}
}
let
(
:mr_params
)
{
{
title:
'Some feature'
,
source_branch:
'fix'
,
target_branch:
'feature'
}
}
...
...
ee/spec/features/merge_request/user_edits_merge_request_blocking_mrs_spec.rb
View file @
c027920b
...
@@ -5,7 +5,7 @@ require 'spec_helper'
...
@@ -5,7 +5,7 @@ require 'spec_helper'
RSpec
.
describe
"User edits merge request with blocking MRs"
,
:js
do
RSpec
.
describe
"User edits merge request with blocking MRs"
,
:js
do
let
(
:merge_request
)
{
create
(
:merge_request
)
}
let
(
:merge_request
)
{
create
(
:merge_request
)
}
let
(
:project
)
{
merge_request
.
target_project
}
let
(
:project
)
{
merge_request
.
target_project
}
let
(
:user
)
{
merge_request
.
target_project
.
owner
}
let
(
:user
)
{
merge_request
.
target_project
.
first_
owner
}
let
(
:other_mr
)
{
create
(
:merge_request
)
}
let
(
:other_mr
)
{
create
(
:merge_request
)
}
...
...
ee/spec/features/merge_trains/two_merge_requests_on_train_spec.rb
View file @
c027920b
...
@@ -6,7 +6,7 @@ RSpec.describe 'Two merge requests on a merge train' do
...
@@ -6,7 +6,7 @@ RSpec.describe 'Two merge requests on a merge train' do
include
RepoHelpers
include
RepoHelpers
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:key
)
{
create
(
:key
,
user:
project
.
owner
)
}
let
(
:key
)
{
create
(
:key
,
user:
project
.
first_
owner
)
}
let_it_be
(
:maintainer_1
)
{
create
(
:user
)
}
let_it_be
(
:maintainer_1
)
{
create
(
:user
)
}
let_it_be
(
:maintainer_2
)
{
create
(
:user
)
}
let_it_be
(
:maintainer_2
)
{
create
(
:user
)
}
...
...
ee/spec/features/projects/active_tabs_spec.rb
View file @
c027920b
...
@@ -5,7 +5,7 @@ require 'spec_helper'
...
@@ -5,7 +5,7 @@ require 'spec_helper'
RSpec
.
describe
'Project active tab'
do
RSpec
.
describe
'Project active tab'
do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
sign_in
(
user
)
sign_in
(
user
)
...
...
ee/spec/features/projects/audit_events_spec.rb
View file @
c027920b
...
@@ -127,7 +127,7 @@ RSpec.describe 'Projects > Audit Events', :js do
...
@@ -127,7 +127,7 @@ RSpec.describe 'Projects > Audit Events', :js do
page
.
within
(
'.audit-log-table'
)
do
page
.
within
(
'.audit-log-table'
)
do
expect
(
page
).
to
have_content
'Changed access level from Developer to Maintainer'
expect
(
page
).
to
have_content
'Changed access level from Developer to Maintainer'
expect
(
page
).
to
have_content
(
project
.
owner
.
name
)
expect
(
page
).
to
have_content
(
project
.
first_
owner
.
name
)
expect
(
page
).
to
have_content
(
'Pete'
)
expect
(
page
).
to
have_content
(
'Pete'
)
end
end
end
end
...
@@ -166,7 +166,7 @@ RSpec.describe 'Projects > Audit Events', :js do
...
@@ -166,7 +166,7 @@ RSpec.describe 'Projects > Audit Events', :js do
wait_for_all_requests
wait_for_all_requests
page
.
within
(
'.audit-log-table'
)
do
page
.
within
(
'.audit-log-table'
)
do
expect
(
page
).
to
have_content
(
project
.
owner
.
name
)
expect
(
page
).
to
have_content
(
project
.
first_
owner
.
name
)
expect
(
page
).
to
have_content
(
'Changed prevent merge request approval from authors'
)
expect
(
page
).
to
have_content
(
'Changed prevent merge request approval from authors'
)
expect
(
page
).
to
have_content
(
'Changed prevent merge request approval from committers'
)
expect
(
page
).
to
have_content
(
'Changed prevent merge request approval from committers'
)
expect
(
page
).
to
have_content
(
project
.
name
)
expect
(
page
).
to
have_content
(
project
.
name
)
...
...
ee/spec/features/projects/kerberos_clone_instructions_spec.rb
View file @
c027920b
...
@@ -5,7 +5,7 @@ RSpec.describe 'Kerberos clone instructions', :js do
...
@@ -5,7 +5,7 @@ RSpec.describe 'Kerberos clone instructions', :js do
include
MobileHelpers
include
MobileHelpers
let
(
:project
)
{
create
(
:project
,
:empty_repo
)
}
let
(
:project
)
{
create
(
:project
,
:empty_repo
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
sign_in
(
user
)
sign_in
(
user
)
...
...
ee/spec/features/projects/navbar_spec.rb
View file @
c027920b
...
@@ -9,7 +9,7 @@ RSpec.describe 'Project navbar' do
...
@@ -9,7 +9,7 @@ RSpec.describe 'Project navbar' do
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
sign_in
(
user
)
sign_in
(
user
)
...
...
ee/spec/features/projects/settings/user_manages_approval_settings_spec.rb
View file @
c027920b
...
@@ -4,7 +4,7 @@ require 'spec_helper'
...
@@ -4,7 +4,7 @@ require 'spec_helper'
RSpec
.
describe
'EE > Projects > Settings > User manages approval rule settings'
do
RSpec
.
describe
'EE > Projects > Settings > User manages approval rule settings'
do
let
(
:project
)
{
create
(
:project
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
let
(
:path
)
{
edit_project_path
(
project
)
}
let
(
:path
)
{
edit_project_path
(
project
)
}
let
(
:licensed_features
)
{
{}
}
let
(
:licensed_features
)
{
{}
}
let
(
:project_features
)
{
{}
}
let
(
:project_features
)
{
{}
}
...
...
ee/spec/features/projects/view_blob_with_code_owners_spec.rb
View file @
c027920b
...
@@ -4,7 +4,7 @@ require 'spec_helper'
...
@@ -4,7 +4,7 @@ require 'spec_helper'
RSpec
.
describe
'File blob > Code owners'
,
:js
do
RSpec
.
describe
'File blob > Code owners'
,
:js
do
let
(
:project
)
{
create
(
:project
,
:private
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:private
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
let
(
:code_owner
)
{
create
(
:user
,
username:
'documentation-owner'
)
}
let
(
:code_owner
)
{
create
(
:user
,
username:
'documentation-owner'
)
}
before
do
before
do
...
...
ee/spec/features/projects_spec.rb
View file @
c027920b
...
@@ -38,7 +38,7 @@ RSpec.describe 'Project', :js do
...
@@ -38,7 +38,7 @@ RSpec.describe 'Project', :js do
describe
'immediately deleting a project marked for deletion'
do
describe
'immediately deleting a project marked for deletion'
do
let
(
:project
)
{
create
(
:project
,
marked_for_deletion_at:
Date
.
current
)
}
let
(
:project
)
{
create
(
:project
,
marked_for_deletion_at:
Date
.
current
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
stub_licensed_features
(
adjourned_deletion_for_projects_and_groups:
true
)
stub_licensed_features
(
adjourned_deletion_for_projects_and_groups:
true
)
...
...
ee/spec/features/protected_branches_spec.rb
View file @
c027920b
...
@@ -6,7 +6,7 @@ RSpec.describe 'Protected Branches', :js do
...
@@ -6,7 +6,7 @@ RSpec.describe 'Protected Branches', :js do
include
ProtectedBranchHelpers
include
ProtectedBranchHelpers
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
sign_in
(
user
)
sign_in
(
user
)
...
...
ee/spec/features/protected_tags_spec.rb
View file @
c027920b
...
@@ -6,7 +6,7 @@ RSpec.describe 'Protected Tags', :js do
...
@@ -6,7 +6,7 @@ RSpec.describe 'Protected Tags', :js do
include
ProtectedTagHelpers
include
ProtectedTagHelpers
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:project
)
{
create
(
:project
,
:repository
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
before
do
before
do
sign_in
(
user
)
sign_in
(
user
)
...
...
ee/spec/features/security/project/snippet/internal_access_spec.rb
View file @
c027920b
...
@@ -6,8 +6,8 @@ RSpec.describe "Internal Project Snippets Access" do
...
@@ -6,8 +6,8 @@ RSpec.describe "Internal Project Snippets Access" do
include
AccessMatchers
include
AccessMatchers
let_it_be
(
:project
)
{
create
(
:project
,
:internal
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:internal
)
}
let_it_be
(
:internal_snippet
)
{
create
(
:project_snippet
,
:internal
,
project:
project
,
author:
project
.
owner
)
}
let_it_be
(
:internal_snippet
)
{
create
(
:project_snippet
,
:internal
,
project:
project
,
author:
project
.
first_
owner
)
}
let_it_be
(
:private_snippet
)
{
create
(
:project_snippet
,
:private
,
project:
project
,
author:
project
.
owner
)
}
let_it_be
(
:private_snippet
)
{
create
(
:project_snippet
,
:private
,
project:
project
,
author:
project
.
first_
owner
)
}
describe
"GET /:project_path/snippets"
do
describe
"GET /:project_path/snippets"
do
subject
{
project_snippets_path
(
project
)
}
subject
{
project_snippets_path
(
project
)
}
...
...
ee/spec/features/security/project/snippet/private_access_spec.rb
View file @
c027920b
...
@@ -6,7 +6,7 @@ RSpec.describe "Private Project Snippets Access" do
...
@@ -6,7 +6,7 @@ RSpec.describe "Private Project Snippets Access" do
include
AccessMatchers
include
AccessMatchers
let_it_be
(
:project
)
{
create
(
:project
,
:private
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:private
)
}
let_it_be
(
:private_snippet
)
{
create
(
:project_snippet
,
:private
,
project:
project
,
author:
project
.
owner
)
}
let_it_be
(
:private_snippet
)
{
create
(
:project_snippet
,
:private
,
project:
project
,
author:
project
.
first_
owner
)
}
describe
"GET /:project_path/snippets"
do
describe
"GET /:project_path/snippets"
do
subject
{
project_snippets_path
(
project
)
}
subject
{
project_snippets_path
(
project
)
}
...
...
ee/spec/features/security/project/snippet/public_access_spec.rb
View file @
c027920b
...
@@ -6,9 +6,9 @@ RSpec.describe "Public Project Snippets Access" do
...
@@ -6,9 +6,9 @@ RSpec.describe "Public Project Snippets Access" do
include
AccessMatchers
include
AccessMatchers
let_it_be
(
:project
)
{
create
(
:project
,
:public
)
}
let_it_be
(
:project
)
{
create
(
:project
,
:public
)
}
let_it_be
(
:public_snippet
)
{
create
(
:project_snippet
,
:public
,
project:
project
,
author:
project
.
owner
)
}
let_it_be
(
:public_snippet
)
{
create
(
:project_snippet
,
:public
,
project:
project
,
author:
project
.
first_
owner
)
}
let_it_be
(
:internal_snippet
)
{
create
(
:project_snippet
,
:internal
,
project:
project
,
author:
project
.
owner
)
}
let_it_be
(
:internal_snippet
)
{
create
(
:project_snippet
,
:internal
,
project:
project
,
author:
project
.
first_
owner
)
}
let_it_be
(
:private_snippet
)
{
create
(
:project_snippet
,
:private
,
project:
project
,
author:
project
.
owner
)
}
let_it_be
(
:private_snippet
)
{
create
(
:project_snippet
,
:private
,
project:
project
,
author:
project
.
first_
owner
)
}
describe
"GET /:project_path/snippets"
do
describe
"GET /:project_path/snippets"
do
subject
{
project_snippets_path
(
project
)
}
subject
{
project_snippets_path
(
project
)
}
...
...
ee/spec/finders/productivity_analytics_finder_spec.rb
View file @
c027920b
...
@@ -6,7 +6,7 @@ RSpec.describe ProductivityAnalyticsFinder do
...
@@ -6,7 +6,7 @@ RSpec.describe ProductivityAnalyticsFinder do
subject
{
described_class
.
new
(
current_user
,
search_params
.
merge
(
state: :merged
))
}
subject
{
described_class
.
new
(
current_user
,
search_params
.
merge
(
state: :merged
))
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:current_user
)
{
project
.
owner
}
let
(
:current_user
)
{
project
.
first_
owner
}
let
(
:search_params
)
{
{}
}
let
(
:search_params
)
{
{}
}
describe
'.array_params'
do
describe
'.array_params'
do
...
...
ee/spec/frontend/fixtures/merge_requests.rb
View file @
c027920b
...
@@ -6,7 +6,7 @@ RSpec.describe Projects::MergeRequestsController, '(JavaScript fixtures in EE co
...
@@ -6,7 +6,7 @@ RSpec.describe Projects::MergeRequestsController, '(JavaScript fixtures in EE co
include
JavaScriptFixturesHelpers
include
JavaScriptFixturesHelpers
let
(
:project
)
{
create
(
:project
,
:repository
,
path:
'merge-requests-project'
)
}
let
(
:project
)
{
create
(
:project
,
:repository
,
path:
'merge-requests-project'
)
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
let
(
:merge_request
)
{
create
(
:merge_request
,
source_project:
project
)
}
let
(
:merge_request
)
{
create
(
:merge_request
,
source_project:
project
)
}
render_views
render_views
...
...
ee/spec/frontend/fixtures/projects.rb
View file @
c027920b
...
@@ -10,7 +10,7 @@ RSpec.describe 'Projects (JavaScript fixtures)', type: :controller do
...
@@ -10,7 +10,7 @@ RSpec.describe 'Projects (JavaScript fixtures)', type: :controller do
let
(
:namespace
)
{
create
(
:namespace
,
name:
'frontend-fixtures'
)}
let
(
:namespace
)
{
create
(
:namespace
,
name:
'frontend-fixtures'
)}
let
(
:project
)
{
create
(
:project
,
namespace:
namespace
,
path:
'builds-project'
,
runners_token:
runners_token
,
avatar:
fixture_file_upload
(
'spec/fixtures/dk.png'
,
'image/png'
))
}
let
(
:project
)
{
create
(
:project
,
namespace:
namespace
,
path:
'builds-project'
,
runners_token:
runners_token
,
avatar:
fixture_file_upload
(
'spec/fixtures/dk.png'
,
'image/png'
))
}
let
(
:user
)
{
project
.
owner
}
let
(
:user
)
{
project
.
first_
owner
}
describe
GraphQL
::
Query
,
type: :request
do
describe
GraphQL
::
Query
,
type: :request
do
include
GraphqlHelpers
include
GraphqlHelpers
...
...
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