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
e95a58f3
Commit
e95a58f3
authored
Feb 13, 2020
by
Adrien Kohlbecker
Committed by
Kushal Pandya
Feb 13, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix k8s logs alert display state
parent
7343c4f2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
6 deletions
+16
-6
changelogs/unreleased/ak-fix-alert.yml
changelogs/unreleased/ak-fix-alert.yml
+5
-0
ee/app/assets/javascripts/logs/components/environment_logs.vue
...p/assets/javascripts/logs/components/environment_logs.vue
+2
-6
ee/spec/frontend/logs/components/environment_logs_spec.js
ee/spec/frontend/logs/components/environment_logs_spec.js
+9
-0
No files found.
changelogs/unreleased/ak-fix-alert.yml
0 → 100644
View file @
e95a58f3
---
title
:
Fix k8s logs alert display state
merge_request
:
24802
author
:
type
:
fixed
ee/app/assets/javascripts/logs/components/environment_logs.vue
View file @
e95a58f3
...
...
@@ -72,11 +72,7 @@ export default {
return
this
.
environments
.
isLoading
||
!
this
.
advancedFeaturesEnabled
;
},
shouldShowElasticStackCallout
()
{
return
(
!
this
.
isElasticStackCalloutDismissed
&&
!
this
.
logs
.
isLoading
&&
!
this
.
disableAdvancedControls
);
return
!
this
.
isElasticStackCalloutDismissed
&&
this
.
disableAdvancedControls
;
},
},
watch
:
{
...
...
@@ -114,7 +110,7 @@ export default {
<div
class=
"build-page-pod-logs mt-3"
>
<gl-alert
v-if=
"shouldShowElasticStackCallout"
class=
"mb-3"
class=
"mb-3
js-elasticsearch-alert
"
@
dismiss=
"isElasticStackCalloutDismissed = true"
>
{{
...
...
ee/spec/frontend/logs/components/environment_logs_spec.js
View file @
e95a58f3
...
...
@@ -46,6 +46,7 @@ describe('EnvironmentLogs', () => {
const
findPodsDropdown
=
()
=>
wrapper
.
find
(
'
.js-pods-dropdown
'
);
const
findSearchBar
=
()
=>
wrapper
.
find
(
'
.js-logs-search
'
);
const
findTimeRangePicker
=
()
=>
wrapper
.
find
({
ref
:
'
dateTimePicker
'
});
const
findInfoAlert
=
()
=>
wrapper
.
find
(
'
.js-elasticsearch-alert
'
);
const
findLogControlButtons
=
()
=>
wrapper
.
find
({
name
:
'
log-control-buttons-stub
'
});
const
findLogTrace
=
()
=>
wrapper
.
find
(
'
.js-log-trace
'
);
...
...
@@ -224,6 +225,10 @@ describe('EnvironmentLogs', () => {
expect
(
actionMocks
.
setSearch
).
not
.
toHaveBeenCalled
();
});
it
(
'
displays an alert to upgrade to ES
'
,
()
=>
{
expect
(
findInfoAlert
().
exists
()).
toBe
(
true
);
});
});
describe
(
'
state with data
'
,
()
=>
{
...
...
@@ -259,6 +264,10 @@ describe('EnvironmentLogs', () => {
expect
(
findTimeRangePicker
().
attributes
(
'
disabled
'
)).
toBeFalsy
();
});
it
(
'
does not display an alert to upgrade to ES
'
,
()
=>
{
expect
(
findInfoAlert
().
exists
()).
toBe
(
false
);
});
it
(
'
populates environments dropdown
'
,
()
=>
{
const
items
=
findEnvironmentsDropdown
().
findAll
(
GlDropdownItem
);
expect
(
findEnvironmentsDropdown
().
props
(
'
text
'
)).
toBe
(
mockEnvName
);
...
...
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