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
0
Merge Requests
0
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
Tatuya Kamada
gitlab-ce
Commits
a3d8c0b2
Commit
a3d8c0b2
authored
Jan 19, 2017
by
Robert Speicher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Convert MoveToProjectFinder specs to use `:empty_project`
parent
7e6ff8ca
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
10 deletions
+10
-10
spec/finders/move_to_project_finder_spec.rb
spec/finders/move_to_project_finder_spec.rb
+10
-10
No files found.
spec/finders/move_to_project_finder_spec.rb
View file @
a3d8c0b2
...
...
@@ -2,13 +2,13 @@ require 'spec_helper'
describe
MoveToProjectFinder
do
let
(
:user
)
{
create
(
:user
)
}
let
(
:project
)
{
create
(
:project
)
}
let
(
:project
)
{
create
(
:
empty_
project
)
}
let
(
:no_access_project
)
{
create
(
:project
)
}
let
(
:guest_project
)
{
create
(
:project
)
}
let
(
:reporter_project
)
{
create
(
:project
)
}
let
(
:developer_project
)
{
create
(
:project
)
}
let
(
:master_project
)
{
create
(
:project
)
}
let
(
:no_access_project
)
{
create
(
:
empty_
project
)
}
let
(
:guest_project
)
{
create
(
:
empty_
project
)
}
let
(
:reporter_project
)
{
create
(
:
empty_
project
)
}
let
(
:developer_project
)
{
create
(
:
empty_
project
)
}
let
(
:master_project
)
{
create
(
:
empty_
project
)
}
subject
{
described_class
.
new
(
user
)
}
...
...
@@ -37,7 +37,7 @@ describe MoveToProjectFinder do
it
'does not return archived projects'
do
reporter_project
.
team
<<
[
user
,
:reporter
]
reporter_project
.
update_attributes
(
archived:
true
)
other_reporter_project
=
create
(
:project
)
other_reporter_project
=
create
(
:
empty_
project
)
other_reporter_project
.
team
<<
[
user
,
:reporter
]
expect
(
subject
.
execute
(
project
).
to_a
).
to
eq
([
other_reporter_project
])
...
...
@@ -46,7 +46,7 @@ describe MoveToProjectFinder do
it
'does not return projects for which issues are disabled'
do
reporter_project
.
team
<<
[
user
,
:reporter
]
reporter_project
.
update_attributes
(
issues_enabled:
false
)
other_reporter_project
=
create
(
:project
)
other_reporter_project
=
create
(
:
empty_
project
)
other_reporter_project
.
team
<<
[
user
,
:reporter
]
expect
(
subject
.
execute
(
project
).
to_a
).
to
eq
([
other_reporter_project
])
...
...
@@ -83,10 +83,10 @@ describe MoveToProjectFinder do
end
it
'returns projects matching a search query'
do
foo_project
=
create
(
:project
)
foo_project
=
create
(
:
empty_
project
)
foo_project
.
team
<<
[
user
,
:master
]
wadus_project
=
create
(
:project
,
name:
'wadus'
)
wadus_project
=
create
(
:
empty_
project
,
name:
'wadus'
)
wadus_project
.
team
<<
[
user
,
:master
]
expect
(
subject
.
execute
(
project
).
to_a
).
to
eq
([
wadus_project
,
foo_project
])
...
...
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