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
ccabf848
Commit
ccabf848
authored
Jun 21, 2018
by
Dennis Tang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix EE tests
parent
b5512847
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
ee/spec/features/projects/clusters_spec.rb
ee/spec/features/projects/clusters_spec.rb
+8
-8
No files found.
ee/spec/features/projects/clusters_spec.rb
View file @
ccabf848
...
@@ -32,7 +32,7 @@ feature 'EE Clusters', :js do
...
@@ -32,7 +32,7 @@ feature 'EE Clusters', :js do
context
'when user filled form with environment scope'
do
context
'when user filled form with environment scope'
do
before
do
before
do
click_link
'Add Kubernetes cluster'
click_link
'Add Kubernetes cluster'
click_link
'Add
an existing Kubernetes
cluster'
click_link
'Add
existing
cluster'
fill_in
'cluster_name'
,
with:
'staging-cluster'
fill_in
'cluster_name'
,
with:
'staging-cluster'
fill_in
'cluster_environment_scope'
,
with:
'staging/*'
fill_in
'cluster_environment_scope'
,
with:
'staging/*'
click_button
'Add Kubernetes cluster'
click_button
'Add Kubernetes cluster'
...
@@ -61,7 +61,7 @@ feature 'EE Clusters', :js do
...
@@ -61,7 +61,7 @@ feature 'EE Clusters', :js do
context
'when user updates duplicated environment scope'
do
context
'when user updates duplicated environment scope'
do
before
do
before
do
click_link
'Add Kubernetes cluster'
click_link
'Add Kubernetes cluster'
click_link
'Add
an existing Kubernetes
cluster'
click_link
'Add
existing
cluster'
fill_in
'cluster_name'
,
with:
'staging-cluster'
fill_in
'cluster_name'
,
with:
'staging-cluster'
fill_in
'cluster_environment_scope'
,
with:
'*'
fill_in
'cluster_environment_scope'
,
with:
'*'
click_button
'Add Kubernetes cluster'
click_button
'Add Kubernetes cluster'
...
@@ -75,13 +75,13 @@ feature 'EE Clusters', :js do
...
@@ -75,13 +75,13 @@ feature 'EE Clusters', :js do
context
'when user adds an Google Kubernetes Engine cluster'
do
context
'when user adds an Google Kubernetes Engine cluster'
do
before
do
before
do
allow_any_instance_of
(
Projects
::
Clusters
::
Gcp
Controller
)
allow_any_instance_of
(
Projects
::
ClustersController
)
.
to
receive
(
:token_in_session
).
and_return
(
'token'
)
.
to
receive
(
:token_in_session
).
and_return
(
'token'
)
allow_any_instance_of
(
Projects
::
Clusters
::
Gcp
Controller
)
allow_any_instance_of
(
Projects
::
ClustersController
)
.
to
receive
(
:expires_at_in_session
).
and_return
(
1
.
hour
.
since
.
to_i
.
to_s
)
.
to
receive
(
:expires_at_in_session
).
and_return
(
1
.
hour
.
since
.
to_i
.
to_s
)
allow_any_instance_of
(
Projects
::
Clusters
::
Gcp
Controller
).
to
receive
(
:authorize_google_project_billing
)
allow_any_instance_of
(
Projects
::
ClustersController
).
to
receive
(
:authorize_google_project_billing
)
allow_any_instance_of
(
Projects
::
Clusters
::
Gcp
Controller
).
to
receive
(
:google_project_billing_status
).
and_return
(
true
)
allow_any_instance_of
(
Projects
::
ClustersController
).
to
receive
(
:google_project_billing_status
).
and_return
(
true
)
allow_any_instance_of
(
GoogleApi
::
CloudPlatform
::
Client
)
allow_any_instance_of
(
GoogleApi
::
CloudPlatform
::
Client
)
.
to
receive
(
:projects_zones_clusters_create
)
do
.
to
receive
(
:projects_zones_clusters_create
)
do
...
@@ -105,7 +105,7 @@ feature 'EE Clusters', :js do
...
@@ -105,7 +105,7 @@ feature 'EE Clusters', :js do
context
'when user filled form with environment scope'
do
context
'when user filled form with environment scope'
do
before
do
before
do
click_link
'Add Kubernetes cluster'
click_link
'Add Kubernetes cluster'
click_link
'Create
on Google Kubernetes Engine
'
click_link
'Create
new Cluster on GKE
'
sleep
2
# wait for ajax
sleep
2
# wait for ajax
execute_script
(
'document.querySelector(".js-gcp-project-id-dropdown input").setAttribute("type", "text")'
)
execute_script
(
'document.querySelector(".js-gcp-project-id-dropdown input").setAttribute("type", "text")'
)
...
@@ -144,7 +144,7 @@ feature 'EE Clusters', :js do
...
@@ -144,7 +144,7 @@ feature 'EE Clusters', :js do
context
'when user updates duplicated environment scope'
do
context
'when user updates duplicated environment scope'
do
before
do
before
do
click_link
'Add Kubernetes cluster'
click_link
'Add Kubernetes cluster'
click_link
'Create
on Google Kubernetes Engine
'
click_link
'Create
new Cluster on GKE
'
sleep
2
# wait for ajax
sleep
2
# wait for ajax
execute_script
(
'document.querySelector(".js-gcp-project-id-dropdown input").setAttribute("type", "text")'
)
execute_script
(
'document.querySelector(".js-gcp-project-id-dropdown input").setAttribute("type", "text")'
)
...
...
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