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
1f7e0672
Commit
1f7e0672
authored
Dec 05, 2018
by
Mike Greiling
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update test to ensure the correct applications are shown
parent
4ead30ab
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
8 deletions
+55
-8
spec/javascripts/clusters/components/applications_spec.js
spec/javascripts/clusters/components/applications_spec.js
+55
-8
No files found.
spec/javascripts/clusters/components/applications_spec.js
View file @
1f7e0672
import
Vue
from
'
vue
'
;
import
Vue
from
'
vue
'
;
import
applications
from
'
~/clusters/components/applications.vue
'
;
import
applications
from
'
~/clusters/components/applications.vue
'
;
import
{
CLUSTER_TYPE
}
from
'
~/clusters/constants
'
;
import
mountComponent
from
'
spec/helpers/vue_mount_component_helper
'
;
import
mountComponent
from
'
spec/helpers/vue_mount_component_helper
'
;
describe
(
'
Applications
'
,
()
=>
{
describe
(
'
Applications
'
,
()
=>
{
...
@@ -14,9 +15,10 @@ describe('Applications', () => {
...
@@ -14,9 +15,10 @@ describe('Applications', () => {
vm
.
$destroy
();
vm
.
$destroy
();
});
});
describe
(
''
,
()
=>
{
describe
(
'
Project cluster applications
'
,
()
=>
{
beforeEach
(()
=>
{
beforeEach
(()
=>
{
vm
=
mountComponent
(
Applications
,
{
vm
=
mountComponent
(
Applications
,
{
type
:
CLUSTER_TYPE
.
PROJECT
,
applications
:
{
applications
:
{
helm
:
{
title
:
'
Helm Tiller
'
},
helm
:
{
title
:
'
Helm Tiller
'
},
ingress
:
{
title
:
'
Ingress
'
},
ingress
:
{
title
:
'
Ingress
'
},
...
@@ -30,31 +32,76 @@ describe('Applications', () => {
...
@@ -30,31 +32,76 @@ describe('Applications', () => {
});
});
it
(
'
renders a row for Helm Tiller
'
,
()
=>
{
it
(
'
renders a row for Helm Tiller
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-helm
'
)).
toBeDefined
();
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-helm
'
)).
not
.
toBeNull
();
});
});
it
(
'
renders a row for Ingress
'
,
()
=>
{
it
(
'
renders a row for Ingress
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-ingress
'
)).
toBeDefined
();
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-ingress
'
)).
not
.
toBeNull
();
});
});
it
(
'
renders a row for Cert-Manager
'
,
()
=>
{
it
(
'
renders a row for Cert-Manager
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-cert_manager
'
)).
toBeDefined
();
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-cert_manager
'
)).
not
.
toBeNull
();
});
});
it
(
'
renders a row for Prometheus
'
,
()
=>
{
it
(
'
renders a row for Prometheus
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-prometheus
'
)).
toBeDefined
();
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-prometheus
'
)).
not
.
toBeNull
();
});
});
it
(
'
renders a row for GitLab Runner
'
,
()
=>
{
it
(
'
renders a row for GitLab Runner
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-runner
'
)).
toBeDefined
();
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-runner
'
)).
not
.
toBeNull
();
});
});
it
(
'
renders a row for Jupyter
'
,
()
=>
{
it
(
'
renders a row for Jupyter
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-jupyter
'
)).
not
.
toBe
(
null
);
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-jupyter
'
)).
not
.
toBe
Null
(
);
});
});
it
(
'
renders a row for Knative
'
,
()
=>
{
it
(
'
renders a row for Knative
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-knative
'
)).
not
.
toBe
(
null
);
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-knative
'
)).
not
.
toBeNull
();
});
});
describe
(
'
Group cluster applications
'
,
()
=>
{
beforeEach
(()
=>
{
vm
=
mountComponent
(
Applications
,
{
type
:
CLUSTER_TYPE
.
GROUP
,
applications
:
{
helm
:
{
title
:
'
Helm Tiller
'
},
ingress
:
{
title
:
'
Ingress
'
},
cert_manager
:
{
title
:
'
Cert-Manager
'
},
runner
:
{
title
:
'
GitLab Runner
'
},
prometheus
:
{
title
:
'
Prometheus
'
},
jupyter
:
{
title
:
'
JupyterHub
'
},
knative
:
{
title
:
'
Knative
'
},
},
});
});
it
(
'
renders a row for Helm Tiller
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-helm
'
)).
not
.
toBeNull
();
});
it
(
'
renders a row for Ingress
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-ingress
'
)).
not
.
toBeNull
();
});
it
(
'
renders a row for Cert-Manager
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-cert_manager
'
)).
not
.
toBeNull
();
});
it
(
'
renders a row for Prometheus
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-prometheus
'
)).
toBeNull
();
});
it
(
'
renders a row for GitLab Runner
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-runner
'
)).
toBeNull
();
});
it
(
'
renders a row for Jupyter
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-jupyter
'
)).
toBeNull
();
});
it
(
'
renders a row for Knative
'
,
()
=>
{
expect
(
vm
.
$el
.
querySelector
(
'
.js-cluster-application-row-knative
'
)).
toBeNull
();
});
});
});
});
...
...
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