BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
8d7e0bdf
Unverified
Commit
8d7e0bdf
authored
May 28, 2018
by
Matija Čupić
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check the GCP cluster form for the GCP token
parent
1e431464
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletion
+10
-1
gcp_spec.rb
spec/features/projects/clusters/gcp_spec.rb
+10
-1
No files found.
spec/features/projects/clusters/gcp_spec.rb
View file @
8d7e0bdf
...
...
@@ -31,6 +31,8 @@ feature 'Gcp Cluster', :js do
end
context
'when user filled form with valid parameters'
do
subject
{
click_button
'Create Kubernetes cluster'
}
before
do
allow_any_instance_of
(
GoogleApi
::
CloudPlatform
::
Client
)
.
to
receive
(
:projects_zones_clusters_create
)
do
...
...
@@ -52,10 +54,15 @@ feature 'Gcp Cluster', :js do
fill_in
'cluster[provider_gcp_attributes][gcp_project_id]'
,
with:
'gcp-project-123'
fill_in
'cluster[provider_gcp_attributes][zone]'
,
with:
'us-central1-a'
fill_in
'cluster[provider_gcp_attributes][machine_type]'
,
with:
'n1-standard-2'
click_button
'Create Kubernetes cluster'
end
it
'users sees a form with the GCP token'
do
expect
(
page
).
to
have_selector
(
:css
,
'form[data-token="token"]'
)
end
it
'user sees a cluster details page and creation status'
do
subject
expect
(
page
).
to
have_content
(
'Kubernetes cluster is being created on Google Kubernetes Engine...'
)
Clusters
::
Cluster
.
last
.
provider
.
make_created!
...
...
@@ -64,6 +71,8 @@ feature 'Gcp Cluster', :js do
end
it
'user sees a error if something wrong during creation'
do
subject
expect
(
page
).
to
have_content
(
'Kubernetes cluster is being created on Google Kubernetes Engine...'
)
Clusters
::
Cluster
.
last
.
provider
.
make_errored!
(
'Something wrong!'
)
...
...
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