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
bee5c080
Commit
bee5c080
authored
Oct 04, 2017
by
Kamil Trzcinski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Rubocop failures
parent
54831bd4
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
13 additions
and
14 deletions
+13
-14
app/controllers/projects/clusters_controller.rb
app/controllers/projects/clusters_controller.rb
+6
-6
spec/javascripts/fixtures/clusters.rb
spec/javascripts/fixtures/clusters.rb
+0
-1
spec/models/gcp/cluster_spec.rb
spec/models/gcp/cluster_spec.rb
+3
-3
spec/services/ci/create_cluster_service_spec.rb
spec/services/ci/create_cluster_service_spec.rb
+2
-2
spec/workers/wait_for_cluster_creation_worker_spec.rb
spec/workers/wait_for_cluster_creation_worker_spec.rb
+2
-2
No files found.
app/controllers/projects/clusters_controller.rb
View file @
bee5c080
spec/javascripts/fixtures/clusters.rb
View file @
bee5c080
...
@@ -31,5 +31,4 @@ describe Projects::ClustersController, '(JavaScript fixtures)', type: :controlle
...
@@ -31,5 +31,4 @@ describe Projects::ClustersController, '(JavaScript fixtures)', type: :controlle
expect
(
response
).
to
be_success
expect
(
response
).
to
be_success
store_frontend_fixture
(
response
,
example
.
description
)
store_frontend_fixture
(
response
,
example
.
description
)
end
end
end
end
spec/models/gcp/cluster_spec.rb
View file @
bee5c080
...
@@ -34,7 +34,7 @@ describe Gcp::Cluster do
...
@@ -34,7 +34,7 @@ describe Gcp::Cluster do
end
end
context
'when too long'
do
context
'when too long'
do
let
(
:gcp_project_id
)
{
'A'
*
64
}
let
(
:gcp_project_id
)
{
'A'
*
64
}
it
{
is_expected
.
to
be_falsey
}
it
{
is_expected
.
to
be_falsey
}
end
end
...
@@ -62,7 +62,7 @@ describe Gcp::Cluster do
...
@@ -62,7 +62,7 @@ describe Gcp::Cluster do
end
end
context
'when too long'
do
context
'when too long'
do
let
(
:gcp_cluster_name
)
{
'A'
*
64
}
let
(
:gcp_cluster_name
)
{
'A'
*
64
}
it
{
is_expected
.
to
be_falsey
}
it
{
is_expected
.
to
be_falsey
}
end
end
...
@@ -106,7 +106,7 @@ describe Gcp::Cluster do
...
@@ -106,7 +106,7 @@ describe Gcp::Cluster do
end
end
context
'when too long'
do
context
'when too long'
do
let
(
:project_namespace
)
{
'A'
*
64
}
let
(
:project_namespace
)
{
'A'
*
64
}
it
{
is_expected
.
to
be_falsey
}
it
{
is_expected
.
to
be_falsey
}
end
end
...
...
spec/services/ci/create_cluster_service_spec.rb
View file @
bee5c080
...
@@ -13,7 +13,7 @@ describe Ci::CreateClusterService do
...
@@ -13,7 +13,7 @@ describe Ci::CreateClusterService do
gcp_project_id:
'gcp-project'
,
gcp_project_id:
'gcp-project'
,
gcp_cluster_name:
'test-cluster'
,
gcp_cluster_name:
'test-cluster'
,
gcp_cluster_zone:
'us-central1-a'
,
gcp_cluster_zone:
'us-central1-a'
,
gcp_cluster_size:
1
,
gcp_cluster_size:
1
}
}
end
end
...
@@ -34,7 +34,7 @@ describe Ci::CreateClusterService do
...
@@ -34,7 +34,7 @@ describe Ci::CreateClusterService do
gcp_project_id:
'gcp-project'
,
gcp_project_id:
'gcp-project'
,
gcp_cluster_name:
'test-cluster'
,
gcp_cluster_name:
'test-cluster'
,
gcp_cluster_zone:
'us-central1-a'
,
gcp_cluster_zone:
'us-central1-a'
,
gcp_cluster_size:
'ABC'
,
gcp_cluster_size:
'ABC'
}
}
end
end
...
...
spec/workers/wait_for_cluster_creation_worker_spec.rb
View file @
bee5c080
...
@@ -8,7 +8,7 @@ describe WaitForClusterCreationWorker do
...
@@ -8,7 +8,7 @@ describe WaitForClusterCreationWorker do
before
do
before
do
allow
(
operation
).
to
receive
(
:status
).
and_return
(
status
)
allow
(
operation
).
to
receive
(
:status
).
and_return
(
status
)
allow
(
operation
).
to
receive
(
:start_time
).
and_return
(
1
.
minute
s
.
ago
)
allow
(
operation
).
to
receive
(
:start_time
).
and_return
(
1
.
minute
.
ago
)
allow
(
operation
).
to
receive
(
:status_message
).
and_return
(
'error'
)
allow
(
operation
).
to
receive
(
:status_message
).
and_return
(
'error'
)
allow_any_instance_of
(
Ci
::
FetchGcpOperationService
).
to
receive
(
:execute
).
and_yield
(
operation
)
allow_any_instance_of
(
Ci
::
FetchGcpOperationService
).
to
receive
(
:execute
).
and_yield
(
operation
)
end
end
...
@@ -17,7 +17,7 @@ describe WaitForClusterCreationWorker do
...
@@ -17,7 +17,7 @@ describe WaitForClusterCreationWorker do
let
(
:status
)
{
'RUNNING'
}
let
(
:status
)
{
'RUNNING'
}
it
'reschedules worker'
do
it
'reschedules worker'
do
expect
(
WaitForClusterCreationWorker
).
to
receive
(
:perform_in
)
expect
(
described_class
).
to
receive
(
:perform_in
)
described_class
.
new
.
perform
(
cluster
.
id
)
described_class
.
new
.
perform
(
cluster
.
id
)
end
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