forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:elastic/kibana into chore/console…
…-to-np-ready * 'master' of github.com:elastic/kibana: Revert "Revert "[ci] compress jobs for CI stability" (elastic#44584)" add src/plugins to the list of plugin dirs to watch (elastic#45033) De-angularize and EUI-ficate Discover Context control elements (elastic#44474)
- Loading branch information
Showing
61 changed files
with
445 additions
and
471 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,21 @@ | ||
JOB: | ||
- kibana-intake | ||
- x-pack-intake | ||
- kibana-firefoxSmoke | ||
- intake | ||
- firefoxSmoke | ||
- kibana-ciGroup1 | ||
- kibana-ciGroup2 | ||
- kibana-ciGroup3 | ||
- kibana-ciGroup4 | ||
- kibana-ciGroup5 | ||
- kibana-ciGroup6 | ||
- kibana-ciGroup7 | ||
- kibana-ciGroup8 | ||
- kibana-ciGroup9 | ||
- kibana-ciGroup10 | ||
- kibana-ciGroup11 | ||
- kibana-ciGroup12 | ||
- kibana-visualRegression | ||
# - kibana-visualRegression | ||
|
||
# make sure all x-pack-ciGroups are listed in test/scripts/jenkins_xpack_ci_group.sh | ||
- x-pack-firefoxSmoke | ||
- x-pack-ciGroup1 | ||
- x-pack-ciGroup2 | ||
- x-pack-ciGroup3 | ||
- x-pack-ciGroup4 | ||
- x-pack-ciGroup5 | ||
- x-pack-ciGroup6 | ||
- x-pack-ciGroup7 | ||
- x-pack-ciGroup8 | ||
- x-pack-ciGroup9 | ||
- x-pack-ciGroup10 | ||
- x-pack-visualRegression | ||
# - x-pack-visualRegression | ||
|
||
# `~` is yaml for `null` | ||
exclude: ~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
src/legacy/core_plugins/kibana/public/context/components/action_bar/_action_bar.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
.cxtSizePicker { | ||
text-align: center; | ||
width: $euiSize * 5; | ||
|
||
&::-webkit-outer-spin-button, | ||
&::-webkit-inner-spin-button { | ||
appearance: none; // Hide increment and decrement buttons for type="number" input. | ||
margin: 0; | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
src/legacy/core_plugins/kibana/public/context/components/action_bar/_index.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
@import './action_bar'; |
94 changes: 94 additions & 0 deletions
94
src/legacy/core_plugins/kibana/public/context/components/action_bar/action_bar.test.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
/* | ||
* Licensed to Elasticsearch B.V. under one or more contributor | ||
* license agreements. See the NOTICE file distributed with | ||
* this work for additional information regarding copyright | ||
* ownership. Elasticsearch B.V. licenses this file to you under | ||
* the Apache License, Version 2.0 (the "License"); you may | ||
* not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, | ||
* software distributed under the License is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
* KIND, either express or implied. See the License for the | ||
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
|
||
import React from 'react'; | ||
import { mountWithIntl } from 'test_utils/enzyme_helpers'; | ||
import { ActionBar, ActionBarProps } from './action_bar'; | ||
// @ts-ignore | ||
import { findTestSubject } from '@elastic/eui/lib/test'; | ||
import { MAX_CONTEXT_SIZE, MIN_CONTEXT_SIZE } from '../../query_parameters/constants'; | ||
|
||
describe('Test Discover Context ActionBar for successor | predecessor records', () => { | ||
['successors', 'predecessors'].forEach(type => { | ||
const onChangeCount = jest.fn(); | ||
const props = { | ||
defaultStepSize: 5, | ||
docCount: 20, | ||
docCountAvailable: 0, | ||
isDisabled: false, | ||
isLoading: false, | ||
onChangeCount, | ||
type, | ||
} as ActionBarProps; | ||
const wrapper = mountWithIntl(<ActionBar {...props} />); | ||
|
||
const input = findTestSubject(wrapper, `${type}CountPicker`); | ||
const btn = findTestSubject(wrapper, `${type}LoadMoreButton`); | ||
|
||
test(`${type}: Load button click`, () => { | ||
btn.simulate('click'); | ||
expect(onChangeCount).toHaveBeenCalledWith(25); | ||
}); | ||
|
||
test(`${type}: Load button click doesnt submit when MAX_CONTEXT_SIZE was reached`, () => { | ||
onChangeCount.mockClear(); | ||
input.simulate('change', { target: { valueAsNumber: MAX_CONTEXT_SIZE } }); | ||
btn.simulate('click'); | ||
expect(onChangeCount).toHaveBeenCalledTimes(0); | ||
}); | ||
|
||
test(`${type}: Count input change submits on blur`, () => { | ||
input.simulate('change', { target: { valueAsNumber: 123 } }); | ||
input.simulate('blur'); | ||
expect(onChangeCount).toHaveBeenCalledWith(123); | ||
}); | ||
|
||
test(`${type}: Count input change submits on return`, () => { | ||
input.simulate('change', { target: { valueAsNumber: 124 } }); | ||
input.simulate('submit'); | ||
expect(onChangeCount).toHaveBeenCalledWith(124); | ||
}); | ||
|
||
test(`${type}: Count input doesnt submits values higher than MAX_CONTEXT_SIZE `, () => { | ||
onChangeCount.mockClear(); | ||
input.simulate('change', { target: { valueAsNumber: MAX_CONTEXT_SIZE + 1 } }); | ||
input.simulate('submit'); | ||
expect(onChangeCount).toHaveBeenCalledTimes(0); | ||
}); | ||
|
||
test(`${type}: Count input doesnt submits values lower than MIN_CONTEXT_SIZE `, () => { | ||
onChangeCount.mockClear(); | ||
input.simulate('change', { target: { valueAsNumber: MIN_CONTEXT_SIZE - 1 } }); | ||
input.simulate('submit'); | ||
expect(onChangeCount).toHaveBeenCalledTimes(0); | ||
}); | ||
|
||
test(`${type}: Warning about limitation of additional records`, () => { | ||
if (type === 'predecessors') { | ||
expect(findTestSubject(wrapper, 'predecessorsWarningMsg').text()).toBe( | ||
'No documents newer than the anchor could be found.' | ||
); | ||
} else { | ||
expect(findTestSubject(wrapper, 'successorsWarningMsg').text()).toBe( | ||
'No documents older than the anchor could be found.' | ||
); | ||
} | ||
}); | ||
}); | ||
}); |
Oops, something went wrong.