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
Léo-Paul Géneau
gitlab-ce
Commits
8a0aeab8
Commit
8a0aeab8
authored
Jun 16, 2016
by
Lin Jen-Shin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use active tense, feedback from:
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/4093#note_12501303
parent
314befde
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
spec/models/ci/runner_spec.rb
spec/models/ci/runner_spec.rb
+9
-9
No files found.
spec/models/ci/runner_spec.rb
View file @
8a0aeab8
...
...
@@ -20,17 +20,17 @@ describe Ci::Runner, models: true do
end
describe
'#display_name'
do
it
'
should return
the description if it has a value'
do
it
'
returns
the description if it has a value'
do
runner
=
FactoryGirl
.
build
(
:ci_runner
,
description:
'Linux/Ruby-1.9.3-p448'
)
expect
(
runner
.
display_name
).
to
eq
'Linux/Ruby-1.9.3-p448'
end
it
'
should return
the token if it does not have a description'
do
it
'
returns
the token if it does not have a description'
do
runner
=
FactoryGirl
.
create
(
:ci_runner
)
expect
(
runner
.
display_name
).
to
eq
runner
.
description
end
it
'
should return
the token if the description is an empty string'
do
it
'
returns
the token if the description is an empty string'
do
runner
=
FactoryGirl
.
build
(
:ci_runner
,
description:
''
,
token:
'token'
)
expect
(
runner
.
display_name
).
to
eq
runner
.
token
end
...
...
@@ -277,13 +277,13 @@ describe Ci::Runner, models: true do
runner
.
update
(
is_shared:
true
)
end
context
'
should
not give owned runner'
do
context
'
does
not give owned runner'
do
subject
{
Ci
::
Runner
.
available_for
(
project
)
}
it
{
is_expected
.
to
be_empty
}
end
context
'
should
not give shared runner'
do
context
'
does
not give shared runner'
do
subject
{
Ci
::
Runner
.
available_for
(
another_project
)
}
it
{
is_expected
.
to
be_empty
}
...
...
@@ -291,13 +291,13 @@ describe Ci::Runner, models: true do
end
context
'with unlocked runner'
do
context
'
should
not give owned runner'
do
context
'
does
not give owned runner'
do
subject
{
Ci
::
Runner
.
available_for
(
project
)
}
it
{
is_expected
.
to
be_empty
}
end
context
'
should
give a specific runner'
do
context
'
does
give a specific runner'
do
subject
{
Ci
::
Runner
.
available_for
(
another_project
)
}
it
{
is_expected
.
to
contain_exactly
(
runner
)
}
...
...
@@ -309,13 +309,13 @@ describe Ci::Runner, models: true do
runner
.
update
(
locked:
true
)
end
context
'
should
not give owned runner'
do
context
'
does
not give owned runner'
do
subject
{
Ci
::
Runner
.
available_for
(
project
)
}
it
{
is_expected
.
to
be_empty
}
end
context
'
should
not give a locked runner'
do
context
'
does
not give a locked runner'
do
subject
{
Ci
::
Runner
.
available_for
(
another_project
)
}
it
{
is_expected
.
to
be_empty
}
...
...
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