mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
[Chore] Remove third-party testing internals from test snapshots (#192747)
## Summary This removes some indavertent testing of third-party APIs/implementations caused by directly passing the result of a `render()` call to `toMatchSnapshot()`. In all cases, this was solved by passing `render().container` (the root element rendered by the testing library) instead. These changes remove implementation details of both styled-components (#192368 being the reason for this commit) and testing-library from the snapshots. ### Checklist - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
This commit is contained in:
parent
48de1a57e7
commit
4efcc28d78
34 changed files with 2394 additions and 9569 deletions
|
@ -1,659 +1,224 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`FieldComponent should allow user to clear values if isClearable is true 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 2;"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right"
|
||||
>
|
||||
<button
|
||||
aria-label="Clear input"
|
||||
class="euiFormControlLayoutClearButton emotion-euiFormControlLayoutClearButton"
|
||||
data-test-subj="comboBoxClearButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiFormControlLayoutClearButton__icon emotion-euiFormControlLayoutClearButton__icon-m"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</button>
|
||||
<button
|
||||
aria-label="Open list of options"
|
||||
class="euiFormControlLayoutCustomIcon emotion-euiFormControlLayoutCustomIcon-clickable"
|
||||
data-test-subj="comboBoxToggleListButton"
|
||||
tabindex="-1"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFormControlLayoutCustomIcon__icon"
|
||||
data-euiicon-type="arrowDown"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 2;"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 2;"
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right"
|
||||
>
|
||||
<button
|
||||
aria-label="Clear input"
|
||||
class="euiFormControlLayoutClearButton emotion-euiFormControlLayoutClearButton"
|
||||
data-test-subj="comboBoxClearButton"
|
||||
type="button"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
<span
|
||||
class="euiFormControlLayoutClearButton__icon emotion-euiFormControlLayoutClearButton__icon-m"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right"
|
||||
</button>
|
||||
<button
|
||||
aria-label="Open list of options"
|
||||
class="euiFormControlLayoutCustomIcon emotion-euiFormControlLayoutCustomIcon-clickable"
|
||||
data-test-subj="comboBoxToggleListButton"
|
||||
tabindex="-1"
|
||||
type="button"
|
||||
>
|
||||
<button
|
||||
aria-label="Clear input"
|
||||
class="euiFormControlLayoutClearButton emotion-euiFormControlLayoutClearButton"
|
||||
data-test-subj="comboBoxClearButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiFormControlLayoutClearButton__icon emotion-euiFormControlLayoutClearButton__icon-m"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</button>
|
||||
<button
|
||||
aria-label="Open list of options"
|
||||
class="euiFormControlLayoutCustomIcon emotion-euiFormControlLayoutCustomIcon-clickable"
|
||||
data-test-subj="comboBoxToggleListButton"
|
||||
tabindex="-1"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFormControlLayoutCustomIcon__icon"
|
||||
data-euiicon-type="arrowDown"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFormControlLayoutCustomIcon__icon"
|
||||
data-euiicon-type="arrowDown"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`FieldComponent should render the component disabled if isDisabled is true 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox euiComboBox-isDisabled emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout euiFormControlLayout-isDisabled emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText-disabled"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
disabled=""
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox euiComboBox-isDisabled emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox euiComboBox-isDisabled emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
class="euiFormControlLayout euiFormControlLayout-isDisabled emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout euiFormControlLayout-isDisabled emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText-disabled"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText-disabled"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
disabled=""
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
disabled=""
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`FieldComponent should render the component enabled and displays the selected field correctly 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 1;"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right"
|
||||
>
|
||||
<button
|
||||
aria-label="Open list of options"
|
||||
class="euiFormControlLayoutCustomIcon emotion-euiFormControlLayoutCustomIcon-clickable"
|
||||
data-test-subj="comboBoxToggleListButton"
|
||||
tabindex="-1"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFormControlLayoutCustomIcon__icon"
|
||||
data-euiicon-type="arrowDown"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 1;"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 1;"
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText"
|
||||
data-test-subj="comboBoxInput"
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right"
|
||||
>
|
||||
<button
|
||||
aria-label="Open list of options"
|
||||
class="euiFormControlLayoutCustomIcon emotion-euiFormControlLayoutCustomIcon-clickable"
|
||||
data-test-subj="comboBoxToggleListButton"
|
||||
tabindex="-1"
|
||||
type="button"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFormControlLayoutCustomIcon__icon"
|
||||
data-euiicon-type="arrowDown"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right"
|
||||
>
|
||||
<button
|
||||
aria-label="Open list of options"
|
||||
class="euiFormControlLayoutCustomIcon emotion-euiFormControlLayoutCustomIcon-clickable"
|
||||
data-test-subj="comboBoxToggleListButton"
|
||||
tabindex="-1"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFormControlLayoutCustomIcon__icon"
|
||||
data-euiicon-type="arrowDown"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`FieldComponent should render the loading spinner if isLoading is true when clicked 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox euiComboBox-isDisabled emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout euiFormControlLayout-isDisabled emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 1;"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText-disabled"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
disabled=""
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right-disabled"
|
||||
>
|
||||
<span
|
||||
aria-label="Loading"
|
||||
class="euiLoadingSpinner emotion-euiLoadingSpinner-m"
|
||||
role="progressbar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiComboBox euiComboBox-isDisabled emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox euiComboBox-isDisabled emotion-euiComboBox-fullWidth"
|
||||
data-test-subj="fieldAutocompleteComboBox"
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
>
|
||||
<div
|
||||
class="euiPopover euiInputPopover emotion-euiPopover-block-EuiInputPopover"
|
||||
class="euiFormControlLayout euiFormControlLayout-isDisabled emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout euiFormControlLayout-isDisabled emotion-euiFormControlLayout-fullWidth-euiComboBox__formControlLayout"
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 1;"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
style="--euiFormControlRightIconsCount: 1;"
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText-disabled"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<div
|
||||
class="euiComboBox__inputWrap euiComboBox__inputWrap--plainText emotion-euiComboBoxInputWrapper-plainText-disabled"
|
||||
data-test-subj="comboBoxInput"
|
||||
tabindex="-1"
|
||||
>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
disabled=""
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right-disabled"
|
||||
>
|
||||
<span
|
||||
aria-label="Loading"
|
||||
class="euiLoadingSpinner emotion-euiLoadingSpinner-m"
|
||||
role="progressbar"
|
||||
/>
|
||||
</div>
|
||||
<input
|
||||
aria-autocomplete="list"
|
||||
aria-controls=""
|
||||
aria-expanded="false"
|
||||
aria-invalid="false"
|
||||
autocomplete="off"
|
||||
class="euiComboBox__input emotion-euiComboBoxInput"
|
||||
data-test-subj="comboBoxSearchInput"
|
||||
disabled=""
|
||||
id="generated-id__eui-combobox-id"
|
||||
role="combobox"
|
||||
style="inline-size: 100%;"
|
||||
value="machine.os.raw"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormControlLayoutIcons emotion-euiFormControlLayoutIcons-absolute-right-disabled"
|
||||
>
|
||||
<span
|
||||
aria-label="Loading"
|
||||
class="euiLoadingSpinner emotion-euiLoadingSpinner-m"
|
||||
role="progressbar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -31,7 +31,7 @@ describe('FieldComponent', () => {
|
|||
selectedField={getField('machine.os.raw')}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
const comboBox = wrapper.getByTestId('fieldAutocompleteComboBox');
|
||||
const input = within(comboBox).getByRole('combobox');
|
||||
expect(input).toHaveAttribute('value', 'machine.os.raw');
|
||||
|
@ -52,7 +52,7 @@ describe('FieldComponent', () => {
|
|||
selectedField={getField('machine.os.raw')}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('fieldAutocompleteComboBox').querySelector('input')).toBeDisabled();
|
||||
});
|
||||
it('should render the loading spinner if isLoading is true when clicked', () => {
|
||||
|
@ -72,7 +72,7 @@ describe('FieldComponent', () => {
|
|||
/>
|
||||
);
|
||||
const fieldAutocompleteComboBox = wrapper.getByTestId('fieldAutocompleteComboBox');
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
fireEvent.click(fieldAutocompleteComboBox);
|
||||
expect(wrapper.getByRole('progressbar')).toBeInTheDocument();
|
||||
});
|
||||
|
@ -92,7 +92,7 @@ describe('FieldComponent', () => {
|
|||
selectedField={getField('machine.os.raw')}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('comboBoxClearButton')).toBeInTheDocument();
|
||||
});
|
||||
it('should change the selected value', async () => {
|
||||
|
|
|
@ -1,722 +1,280 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`ExceptionItemCardComments should not render comments when the length is falsy 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ExceptionItemCardComments should not render comments when the length is falsy 1`] = `<div />`;
|
||||
|
||||
exports[`ExceptionItemCardComments should render comments panel closed 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="ExceptionItemCardCommentsContainer"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion emotion-euiAccordion"
|
||||
data-test-subj="exceptionItemCardComments"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__triggerWrapper emotion-EuiAccordionTrigger"
|
||||
>
|
||||
<button
|
||||
aria-controls="exceptionItemCardComments"
|
||||
aria-expanded="false"
|
||||
class="euiAccordion__button emotion-euiAccordion__button"
|
||||
id="generated-id"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiAccordion__buttonContent"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="ExceptionItemCardCommentsContainerTextButton"
|
||||
>
|
||||
Show comments (2)
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
aria-labelledby="generated-id"
|
||||
class="euiAccordion__childWrapper emotion-euiAccordion__childWrapper-isClosed"
|
||||
id="exceptionItemCardComments"
|
||||
inert=""
|
||||
role="group"
|
||||
style="block-size: 0;"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__children emotion-euiAccordion__children"
|
||||
>
|
||||
<div
|
||||
class="euiPanel euiPanel--plain euiPanel--paddingMedium emotion-euiPanel-grow-m-m-plain-hasBorder"
|
||||
data-test-subj="accordionContentPanel"
|
||||
>
|
||||
<ol
|
||||
class="euiTimeline euiCommentList emotion-euiTimeline-l"
|
||||
data-test-subj="accordionCommentList"
|
||||
role="list"
|
||||
>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="ExceptionItemCardCommentsContainer"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="ExceptionItemCardCommentsContainer"
|
||||
class="euiAccordion emotion-euiAccordion"
|
||||
data-test-subj="exceptionItemCardComments"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion emotion-euiAccordion"
|
||||
data-test-subj="exceptionItemCardComments"
|
||||
class="euiAccordion__triggerWrapper emotion-EuiAccordionTrigger"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__triggerWrapper emotion-EuiAccordionTrigger"
|
||||
<button
|
||||
aria-controls="exceptionItemCardComments"
|
||||
aria-expanded="false"
|
||||
class="euiAccordion__button emotion-euiAccordion__button"
|
||||
id="generated-id"
|
||||
type="button"
|
||||
>
|
||||
<button
|
||||
aria-controls="exceptionItemCardComments"
|
||||
aria-expanded="false"
|
||||
class="euiAccordion__button emotion-euiAccordion__button"
|
||||
id="generated-id"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiAccordion__buttonContent"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="ExceptionItemCardCommentsContainerTextButton"
|
||||
>
|
||||
Show comments (2)
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
aria-labelledby="generated-id"
|
||||
class="euiAccordion__childWrapper emotion-euiAccordion__childWrapper-isClosed"
|
||||
id="exceptionItemCardComments"
|
||||
inert=""
|
||||
role="group"
|
||||
style="block-size: 0;"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__children emotion-euiAccordion__children"
|
||||
<span
|
||||
class="euiAccordion__buttonContent"
|
||||
>
|
||||
<div
|
||||
class="euiPanel euiPanel--plain euiPanel--paddingMedium emotion-euiPanel-grow-m-m-plain-hasBorder"
|
||||
data-test-subj="accordionContentPanel"
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="ExceptionItemCardCommentsContainerTextButton"
|
||||
>
|
||||
<ol
|
||||
class="euiTimeline euiCommentList emotion-euiTimeline-l"
|
||||
data-test-subj="accordionCommentList"
|
||||
role="list"
|
||||
>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
Show comments (2)
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
aria-labelledby="generated-id"
|
||||
class="euiAccordion__childWrapper emotion-euiAccordion__childWrapper-isClosed"
|
||||
id="exceptionItemCardComments"
|
||||
inert=""
|
||||
role="group"
|
||||
style="block-size: 0;"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__children emotion-euiAccordion__children"
|
||||
>
|
||||
<div
|
||||
class="euiPanel euiPanel--plain euiPanel--paddingMedium emotion-euiPanel-grow-m-m-plain-hasBorder"
|
||||
data-test-subj="accordionContentPanel"
|
||||
>
|
||||
<ol
|
||||
class="euiTimeline euiCommentList emotion-euiTimeline-l"
|
||||
data-test-subj="accordionCommentList"
|
||||
role="list"
|
||||
>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`ExceptionItemCardComments should render comments panel opened when accordion is clicked 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="ExceptionItemCardCommentsContainer"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion euiAccordion-isOpen emotion-euiAccordion"
|
||||
data-test-subj="exceptionItemCardComments"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__triggerWrapper emotion-EuiAccordionTrigger"
|
||||
>
|
||||
<button
|
||||
aria-controls="exceptionItemCardComments"
|
||||
aria-expanded="true"
|
||||
class="euiAccordion__button emotion-euiAccordion__button"
|
||||
id="generated-id"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiAccordion__buttonContent"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="ExceptionItemCardCommentsContainerTextButton"
|
||||
>
|
||||
Show comments (2)
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
aria-labelledby="generated-id"
|
||||
class="euiAccordion__childWrapper emotion-euiAccordion__childWrapper-isOpen"
|
||||
id="exceptionItemCardComments"
|
||||
role="group"
|
||||
style="block-size: 0;"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__children emotion-euiAccordion__children"
|
||||
>
|
||||
<div
|
||||
class="euiPanel euiPanel--plain euiPanel--paddingMedium emotion-euiPanel-grow-m-m-plain-hasBorder"
|
||||
data-test-subj="accordionContentPanel"
|
||||
>
|
||||
<ol
|
||||
class="euiTimeline euiCommentList emotion-euiTimeline-l"
|
||||
data-test-subj="accordionCommentList"
|
||||
role="list"
|
||||
>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="ExceptionItemCardCommentsContainer"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="ExceptionItemCardCommentsContainer"
|
||||
class="euiAccordion euiAccordion-isOpen emotion-euiAccordion"
|
||||
data-test-subj="exceptionItemCardComments"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion euiAccordion-isOpen emotion-euiAccordion"
|
||||
data-test-subj="exceptionItemCardComments"
|
||||
class="euiAccordion__triggerWrapper emotion-EuiAccordionTrigger"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__triggerWrapper emotion-EuiAccordionTrigger"
|
||||
<button
|
||||
aria-controls="exceptionItemCardComments"
|
||||
aria-expanded="true"
|
||||
class="euiAccordion__button emotion-euiAccordion__button"
|
||||
id="generated-id"
|
||||
type="button"
|
||||
>
|
||||
<button
|
||||
aria-controls="exceptionItemCardComments"
|
||||
aria-expanded="true"
|
||||
class="euiAccordion__button emotion-euiAccordion__button"
|
||||
id="generated-id"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiAccordion__buttonContent"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="ExceptionItemCardCommentsContainerTextButton"
|
||||
>
|
||||
Show comments (2)
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
aria-labelledby="generated-id"
|
||||
class="euiAccordion__childWrapper emotion-euiAccordion__childWrapper-isOpen"
|
||||
id="exceptionItemCardComments"
|
||||
role="group"
|
||||
style="block-size: 0;"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__children emotion-euiAccordion__children"
|
||||
<span
|
||||
class="euiAccordion__buttonContent"
|
||||
>
|
||||
<div
|
||||
class="euiPanel euiPanel--plain euiPanel--paddingMedium emotion-euiPanel-grow-m-m-plain-hasBorder"
|
||||
data-test-subj="accordionContentPanel"
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="ExceptionItemCardCommentsContainerTextButton"
|
||||
>
|
||||
<ol
|
||||
class="euiTimeline euiCommentList emotion-euiTimeline-l"
|
||||
data-test-subj="accordionCommentList"
|
||||
role="list"
|
||||
>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
Show comments (2)
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
aria-labelledby="generated-id"
|
||||
class="euiAccordion__childWrapper emotion-euiAccordion__childWrapper-isOpen"
|
||||
id="exceptionItemCardComments"
|
||||
role="group"
|
||||
style="block-size: 0;"
|
||||
>
|
||||
<div
|
||||
class="euiAccordion__children emotion-euiAccordion__children"
|
||||
>
|
||||
<div
|
||||
class="euiPanel euiPanel--plain euiPanel--paddingMedium emotion-euiPanel-grow-m-m-plain-hasBorder"
|
||||
data-test-subj="accordionContentPanel"
|
||||
>
|
||||
<ol
|
||||
class="euiTimeline euiCommentList emotion-euiTimeline-l"
|
||||
data-test-subj="accordionCommentList"
|
||||
role="list"
|
||||
>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
<li
|
||||
class="euiComment emotion-euiTimelineItem-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon-top"
|
||||
>
|
||||
<div
|
||||
class="emotion-euiTimelineItemIcon__content"
|
||||
>
|
||||
<div
|
||||
aria-label=""
|
||||
class="euiAvatar euiAvatar--m euiAvatar--user euiCommentAvatar emotion-euiAvatar-user-m-uppercase-subdued"
|
||||
role="img"
|
||||
title=""
|
||||
>
|
||||
<span
|
||||
class="euiAvatar__icon"
|
||||
data-euiicon-type="userAvatar"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="emotion-euiTimelineItemEvent-top"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent emotion-euiCommentEvent"
|
||||
data-type="custom"
|
||||
>
|
||||
<div
|
||||
class="euiCommentEvent__body emotion-euiCommentEvent__body-custom"
|
||||
>
|
||||
<p>
|
||||
some old comment
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -19,7 +19,7 @@ describe('ExceptionItemCardComments', () => {
|
|||
const wrapper = render(
|
||||
<ExceptionItemCardComments comments={[]} dataTestSubj="ExceptionItemCardCommentsContainer" />
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.queryByTestId('ExceptionItemCardCommentsContainer')).not.toBeInTheDocument();
|
||||
});
|
||||
|
@ -31,7 +31,7 @@ describe('ExceptionItemCardComments', () => {
|
|||
dataTestSubj="ExceptionItemCardCommentsContainer"
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('ExceptionItemCardCommentsContainer')).toHaveTextContent(
|
||||
i18n.exceptionItemCardCommentsAccordion(comments.length)
|
||||
|
@ -52,6 +52,6 @@ describe('ExceptionItemCardComments', () => {
|
|||
expect(wrapper.getByTestId('accordionContentPanel')).toBeVisible();
|
||||
expect(wrapper.getByTestId('accordionCommentList')).toBeVisible();
|
||||
expect(wrapper.getByTestId('accordionCommentList')).toHaveTextContent('some old comment');
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,164 +1,56 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`EntryContent should render a nested value 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="EntryContentlistlist_id0EntryContent"
|
||||
>
|
||||
<div
|
||||
css="You have tried to stringify object returned from \`css\` function. It isn't supposed to be used directly (e.g. as value of the \`className\` prop), but rather handed to emotion so it can handle it (e.g. as value of \`css\` prop)."
|
||||
>
|
||||
<div
|
||||
data-test-subj="EntryContentlistlist_id0EntryContent"
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-m-flexStart-center-row"
|
||||
data-test-subj="EntryContentNestedEntry"
|
||||
>
|
||||
<span
|
||||
class="euiToken emotion-euiToken-circle-light-s-euiColorVis2"
|
||||
data-test-subj="nstedEntryIcon"
|
||||
>
|
||||
<span
|
||||
data-euiicon-type="tokenNested"
|
||||
/>
|
||||
</span>
|
||||
<div
|
||||
css="You have tried to stringify object returned from \`css\` function. It isn't supposed to be used directly (e.g. as value of the \`className\` prop), but rather handed to emotion so it can handle it (e.g. as value of \`css\` prop)."
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-m-flexStart-center-row"
|
||||
data-test-subj="EntryContentNestedEntry"
|
||||
>
|
||||
<span
|
||||
class="euiToken emotion-euiToken-circle-light-s-euiColorVis2"
|
||||
data-test-subj="nstedEntryIcon"
|
||||
>
|
||||
<span
|
||||
data-euiicon-type="tokenNested"
|
||||
/>
|
||||
</span>
|
||||
<div
|
||||
css="You have tried to stringify object returned from \`css\` function. It isn't supposed to be used directly (e.g. as value of the \`className\` prop), but rather handed to emotion so it can handle it (e.g. as value of \`css\` prop)."
|
||||
>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-subdued"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-subdued-isUppercase"
|
||||
/>
|
||||
|
||||
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="entryValueExpression"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
included in
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
list_id
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
data-test-subj="EntryContentlistlist_id0EntryContent"
|
||||
>
|
||||
<div
|
||||
css="You have tried to stringify object returned from \`css\` function. It isn't supposed to be used directly (e.g. as value of the \`className\` prop), but rather handed to emotion so it can handle it (e.g. as value of \`css\` prop)."
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-m-flexStart-center-row"
|
||||
data-test-subj="EntryContentNestedEntry"
|
||||
>
|
||||
<span
|
||||
class="euiToken emotion-euiToken-circle-light-s-euiColorVis2"
|
||||
data-test-subj="nstedEntryIcon"
|
||||
class="euiExpression emotion-euiExpression-subdued"
|
||||
>
|
||||
<span
|
||||
data-euiicon-type="tokenNested"
|
||||
class="euiExpression__description emotion-euiExpression__description-subdued-isUppercase"
|
||||
/>
|
||||
|
||||
|
||||
</span>
|
||||
<div
|
||||
css="You have tried to stringify object returned from \`css\` function. It isn't supposed to be used directly (e.g. as value of the \`className\` prop), but rather handed to emotion so it can handle it (e.g. as value of \`css\` prop)."
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="entryValueExpression"
|
||||
>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-subdued"
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-subdued-isUppercase"
|
||||
/>
|
||||
|
||||
|
||||
included in
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="entryValueExpression"
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
included in
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
list_id
|
||||
</span>
|
||||
list_id
|
||||
</span>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -53,6 +53,6 @@ describe('EntryContent', () => {
|
|||
expect(wrapper.getByTestId('EntryContentNestedEntry')).toBeInTheDocument();
|
||||
expect(wrapper.getByTestId('nstedEntryIcon')).toBeInTheDocument();
|
||||
expect(wrapper.getByTestId('entryValueExpression')).toHaveTextContent('list_id');
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,467 +1,126 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`OsCondition should render one OS_LABELS 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
OS
|
||||
</span>
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
Mac
|
||||
</span>
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
OS
|
||||
</span>
|
||||
</span>
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
Mac
|
||||
</span>
|
||||
OS
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
Mac
|
||||
</span>
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`OsCondition should render two OS_LABELS 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
OS
|
||||
</span>
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
Mac, Windows
|
||||
</span>
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
OS
|
||||
</span>
|
||||
</span>
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
Mac, Windows
|
||||
</span>
|
||||
OS
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
Mac, Windows
|
||||
</span>
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`OsCondition should return any os sent 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
<div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
OS
|
||||
</span>
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
MacPro
|
||||
</span>
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
data-test-subj="OsConditionMacOs"
|
||||
>
|
||||
<strong>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osLabel"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
OS
|
||||
</span>
|
||||
</span>
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
/>
|
||||
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
MacPro
|
||||
</span>
|
||||
OS
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</span>
|
||||
<span
|
||||
class="euiExpression emotion-euiExpression-success"
|
||||
data-test-subj="osValue"
|
||||
>
|
||||
<span
|
||||
class="euiExpression__description emotion-euiExpression__description-success-isUppercase"
|
||||
>
|
||||
IS
|
||||
</span>
|
||||
|
||||
<span
|
||||
class="euiExpression__value emotion-euiExpression__value"
|
||||
>
|
||||
MacPro
|
||||
</span>
|
||||
</span>
|
||||
</strong>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`OsCondition should return empty body 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`OsCondition should return empty body 1`] = `<div />`;
|
||||
|
|
|
@ -20,7 +20,7 @@ describe('OsCondition', () => {
|
|||
expect(wrapper.getByTestId('osValue')).toHaveTextContent(
|
||||
`${i18n.CONDITION_OPERATOR_TYPE_MATCH} ${OS_LABELS.macos}`
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
it('should render two OS_LABELS', () => {
|
||||
const wrapper = render(<OsCondition os={['macos', 'windows']} dataTestSubj="OsConditionMac" />);
|
||||
|
@ -28,11 +28,11 @@ describe('OsCondition', () => {
|
|||
expect(wrapper.getByTestId('osValue')).toHaveTextContent(
|
||||
`${i18n.CONDITION_OPERATOR_TYPE_MATCH} ${OS_LABELS.macos}, ${OS_LABELS.windows}`
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
it('should return empty body', () => {
|
||||
const wrapper = render(<OsCondition os={[]} dataTestSubj="OsConditionMac" />);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
it('should return any os sent', () => {
|
||||
const wrapper = render(<OsCondition os={['MacPro' as any]} dataTestSubj="OsConditionMac" />);
|
||||
|
@ -40,6 +40,6 @@ describe('OsCondition', () => {
|
|||
expect(wrapper.getByTestId('osValue')).toHaveTextContent(
|
||||
`${i18n.CONDITION_OPERATOR_TYPE_MATCH} MacPro`
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,30 +1,63 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`MetaInfoDetails should render lastUpdate as JSX Element 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="MetaInfoDetailsmetaInfoDetails"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="MetaInfoDetailsmetaInfoDetails"
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
created_by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdate"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="Last update value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
<p>
|
||||
Last update value
|
||||
</p>
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdateValue"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-xs-flexStart-center-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
created_by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdate"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="Last update value"
|
||||
title="value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
|
@ -32,204 +65,73 @@ Object {
|
|||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
<p>
|
||||
Last update value
|
||||
</p>
|
||||
value
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdateValue"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-xs-flexStart-center-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
value
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="MetaInfoDetailsmetaInfoDetails"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
created_by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdate"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="Last update value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
<p>
|
||||
Last update value
|
||||
</p>
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdateValue"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-xs-flexStart-center-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
value
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`MetaInfoDetails should render lastUpdate as string 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="MetaInfoDetailsmetaInfoDetails"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="MetaInfoDetailsmetaInfoDetails"
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
created_by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdate"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="last update"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
last update
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdateValue"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-xs-flexStart-center-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
created_by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdate"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="last update"
|
||||
title="value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
|
@ -237,171 +139,13 @@ Object {
|
|||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
last update
|
||||
value
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdateValue"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-xs-flexStart-center-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
value
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="MetaInfoDetailsmetaInfoDetails"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
created_by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdate"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="last update"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
last update
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
>
|
||||
by
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="MetaInfoDetailslastUpdateValue"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-xs-flexStart-center-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="value"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
value
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -21,7 +21,7 @@ describe('MetaInfoDetails', () => {
|
|||
lastUpdateValue="value"
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('MetaInfoDetailslastUpdate')).toHaveTextContent('last update');
|
||||
});
|
||||
it('should render lastUpdate as JSX Element', () => {
|
||||
|
@ -33,7 +33,7 @@ describe('MetaInfoDetails', () => {
|
|||
lastUpdateValue="value"
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('MetaInfoDetailslastUpdate')).toHaveTextContent('Last update value');
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,247 +1,71 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`generateLinedRulesMenuItems should render the first linked rules with left icon and does not apply the css if the length is 1 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiContextMenuItem css-0"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestActionItem1a2b3c"
|
||||
>
|
||||
<span
|
||||
class="euiContextMenuItem__text emotion-euiContextMenuItem__text"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-s-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestLeftIcon"
|
||||
>
|
||||
<span
|
||||
data-euiicon-type="check"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
data-test-subj="securityLinkAnchorComponent"
|
||||
>
|
||||
<a
|
||||
href="1a2b3c"
|
||||
>
|
||||
Simple Rule Query
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiContextMenuItem css-0"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestActionItem1a2b3c"
|
||||
<div>
|
||||
<div
|
||||
class="euiContextMenuItem css-0"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestActionItem1a2b3c"
|
||||
>
|
||||
<span
|
||||
class="euiContextMenuItem__text emotion-euiContextMenuItem__text"
|
||||
>
|
||||
<span
|
||||
class="euiContextMenuItem__text emotion-euiContextMenuItem__text"
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-s-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-s-flexStart-stretch-row"
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestLeftIcon"
|
||||
>
|
||||
<span
|
||||
data-euiicon-type="check"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestLeftIcon"
|
||||
data-test-subj="securityLinkAnchorComponent"
|
||||
>
|
||||
<span
|
||||
data-euiicon-type="check"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
data-test-subj="securityLinkAnchorComponent"
|
||||
<a
|
||||
href="1a2b3c"
|
||||
>
|
||||
<a
|
||||
href="1a2b3c"
|
||||
>
|
||||
Simple Rule Query
|
||||
</a>
|
||||
</div>
|
||||
Simple Rule Query
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`generateLinedRulesMenuItems should render the second linked rule and apply the css when the length is > 1 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiContextMenuItem emotion-EuiContextMenuItem"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestActionItem2a2b3c"
|
||||
>
|
||||
<span
|
||||
class="euiContextMenuItem__text emotion-euiContextMenuItem__text"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-s-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
data-test-subj="securityLinkAnchorComponent"
|
||||
>
|
||||
<a
|
||||
href="2a2b3c"
|
||||
>
|
||||
Simple Rule Query 2
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiContextMenuItem emotion-EuiContextMenuItem"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestActionItem2a2b3c"
|
||||
<div>
|
||||
<div
|
||||
class="euiContextMenuItem emotion-EuiContextMenuItem"
|
||||
data-test-subj="generateLinedRulesMenuItemsTestActionItem2a2b3c"
|
||||
>
|
||||
<span
|
||||
class="euiContextMenuItem__text emotion-euiContextMenuItem__text"
|
||||
>
|
||||
<span
|
||||
class="euiContextMenuItem__text emotion-euiContextMenuItem__text"
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-s-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-s-flexStart-stretch-row"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="securityLinkAnchorComponent"
|
||||
>
|
||||
<div
|
||||
data-test-subj="securityLinkAnchorComponent"
|
||||
<a
|
||||
href="2a2b3c"
|
||||
>
|
||||
<a
|
||||
href="2a2b3c"
|
||||
>
|
||||
Simple Rule Query 2
|
||||
</a>
|
||||
</div>
|
||||
Simple Rule Query 2
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -47,7 +47,7 @@ describe('generateLinedRulesMenuItems', () => {
|
|||
|
||||
result.map((link) => {
|
||||
const wrapper = render(link);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('generateLinedRulesMenuItemsTestActionItem1a2b3c'));
|
||||
expect(wrapper.getByTestId('generateLinedRulesMenuItemsTestLeftIcon'));
|
||||
});
|
||||
|
@ -56,7 +56,7 @@ describe('generateLinedRulesMenuItems', () => {
|
|||
const result: ReactElement[] = getSecurityLinkAction(dataTestSubj);
|
||||
|
||||
const wrapper = render(result[1]);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('generateLinedRulesMenuItemsTestActionItem2a2b3c'));
|
||||
});
|
||||
});
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -19,7 +19,7 @@ describe('HeaderMenu', () => {
|
|||
<HeaderMenu iconType="boxesHorizontal" disableActions={false} actions={null} />
|
||||
);
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('ButtonIcon')).toBeInTheDocument();
|
||||
expect(wrapper.queryByTestId('EmptyButton')).not.toBeInTheDocument();
|
||||
|
@ -28,7 +28,7 @@ describe('HeaderMenu', () => {
|
|||
it('should not render icon', () => {
|
||||
const wrapper = render(<HeaderMenu disableActions={false} actions={null} />);
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('ButtonIcon')).toBeInTheDocument();
|
||||
expect(wrapper.queryByTestId('EmptyButton')).not.toBeInTheDocument();
|
||||
|
@ -44,7 +44,7 @@ describe('HeaderMenu', () => {
|
|||
);
|
||||
|
||||
fireEvent.click(wrapper.getByTestId('ButtonIcon'));
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('ActionItemdelete')).toBeDisabled();
|
||||
expect(wrapper.getByTestId('ActionItemedit')).toBeEnabled();
|
||||
});
|
||||
|
@ -60,7 +60,7 @@ describe('HeaderMenu', () => {
|
|||
/>
|
||||
);
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('EmptyButton')).toBeInTheDocument();
|
||||
expect(wrapper.queryByTestId('ButtonIcon')).not.toBeInTheDocument();
|
||||
|
@ -79,7 +79,7 @@ describe('HeaderMenu', () => {
|
|||
/>
|
||||
);
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('EmptyButton')).toBeInTheDocument();
|
||||
expect(wrapper.queryByTestId('ButtonIcon')).not.toBeInTheDocument();
|
||||
|
@ -99,7 +99,7 @@ describe('HeaderMenu', () => {
|
|||
/>
|
||||
);
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('EmptyButton')).toBeInTheDocument();
|
||||
expect(wrapper.queryByTestId('ButtonIcon')).not.toBeInTheDocument();
|
||||
|
@ -129,7 +129,7 @@ describe('HeaderMenu', () => {
|
|||
/>
|
||||
);
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.getByTestId('EmptyButton')).toBeInTheDocument();
|
||||
fireEvent.click(wrapper.getByTestId('EmptyButton'));
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,225 +1,3 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`EditModal should render the title and description from listDetails 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
<div
|
||||
class="euiOverlayMask emotion-euiOverlayMask-aboveHeader"
|
||||
data-euiportal="true"
|
||||
data-relative-to-header="above"
|
||||
>
|
||||
<div
|
||||
data-eui="EuiFocusTrap"
|
||||
>
|
||||
<div
|
||||
aria-modal="true"
|
||||
class="euiModal emotion-euiModal-defaultMaxWidth"
|
||||
data-test-subj="EditModal"
|
||||
role="dialog"
|
||||
tabindex="0"
|
||||
>
|
||||
<button
|
||||
aria-label="Closes this modal window"
|
||||
class="euiButtonIcon euiModal__closeIcon emotion-euiButtonIcon-xs-empty-text-euiModal__closeIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</button>
|
||||
<div
|
||||
class="euiModalHeader emotion-euiModalHeader"
|
||||
>
|
||||
<h1
|
||||
class="euiTitle euiModalHeader__title emotion-euiTitle-m"
|
||||
data-test-subj="editModalTitle"
|
||||
>
|
||||
Edit list name
|
||||
</h1>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalBody emotion-euiModalBody"
|
||||
>
|
||||
<div
|
||||
class="euiModalBody__overflow emotion-euiModalBody__overflow"
|
||||
>
|
||||
<form
|
||||
class="euiForm"
|
||||
data-test-subj="editModalForm"
|
||||
id="modalForm_generated-id"
|
||||
>
|
||||
<div
|
||||
class="euiFormRow euiFormRow--hasLabel emotion-euiFormRow-fullWidth"
|
||||
id="generated-id-row"
|
||||
>
|
||||
<div
|
||||
class="euiFormRow__labelWrapper"
|
||||
>
|
||||
<label
|
||||
aria-invalid="false"
|
||||
class="euiFormLabel euiFormRow__label emotion-euiFormLabel"
|
||||
for="generated-id"
|
||||
id="generated-id-label"
|
||||
>
|
||||
Name
|
||||
</label>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormRow__fieldWrapper"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout emotion-euiFormControlLayout-fullWidth"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
>
|
||||
<input
|
||||
class="euiFieldText emotion-euiFieldText-fullWidth"
|
||||
data-test-subj="editModalNameTextField"
|
||||
id="generated-id"
|
||||
name="name"
|
||||
type="text"
|
||||
value="list name"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormRow euiFormRow--hasLabel emotion-euiFormRow-fullWidth"
|
||||
id="generated-id-row"
|
||||
>
|
||||
<div
|
||||
class="euiFormRow__labelWrapper"
|
||||
>
|
||||
<label
|
||||
class="euiFormLabel euiFormRow__label emotion-euiFormLabel"
|
||||
for="generated-id"
|
||||
id="generated-id-label"
|
||||
>
|
||||
Description (optional)
|
||||
</label>
|
||||
</div>
|
||||
<div
|
||||
class="euiFormRow__fieldWrapper"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout euiFormControlLayout--euiTextArea emotion-euiFormControlLayout-fullWidth-euiTextArea"
|
||||
>
|
||||
<div
|
||||
class="euiFormControlLayout__childrenWrapper emotion-euiFormControlLayout__childrenWrapper"
|
||||
>
|
||||
<textarea
|
||||
class="euiTextArea emotion-euiTextArea-vertical-fullWidth"
|
||||
data-test-subj="editModalDescriptionTextField"
|
||||
id="generated-id"
|
||||
name="description"
|
||||
rows="6"
|
||||
>
|
||||
list description
|
||||
</textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalFooter emotion-euiModalFooter"
|
||||
>
|
||||
<button
|
||||
class="euiButtonEmpty emotion-euiButtonDisplay-euiButtonEmpty-m-empty-primary"
|
||||
data-test-subj="editModalCancelBtn"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiButtonEmpty__content emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate euiButtonEmpty__text"
|
||||
>
|
||||
Cancel
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-fill-primary"
|
||||
data-test-subj="editModalSaveBtn"
|
||||
form="modalForm_generated-id"
|
||||
type="submit"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Save
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`EditModal should render the title and description from listDetails 1`] = `<div />`;
|
||||
|
|
|
@ -25,7 +25,7 @@ describe('EditModal', () => {
|
|||
onCancel={onCancel}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('editModalTitle')).toHaveTextContent('list name');
|
||||
});
|
||||
it('should call onSave when submitting the form', () => {
|
||||
|
|
|
@ -47,7 +47,7 @@ describe('ExceptionListHeader', () => {
|
|||
backOptions={{ pageId: '', path: '', onNavigate }}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
fireEvent.click(wrapper.getByTestId('RightSideMenuItemsMenuActionsItems'));
|
||||
expect(wrapper.queryByTestId('RightSideMenuItemsMenuActionsButtonIcon')).toBeDisabled();
|
||||
expect(wrapper.getByTestId('DescriptionText')).toHaveTextContent(
|
||||
|
@ -80,7 +80,7 @@ describe('ExceptionListHeader', () => {
|
|||
);
|
||||
expect(wrapper.queryByTestId('RightSideMenuItemsMenuActionsButtonIcon')).toBeEnabled();
|
||||
fireEvent.click(wrapper.getByTestId('RightSideMenuItemsMenuActionsButtonIcon'));
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
|
||||
expect(wrapper.queryByTestId('RightSideMenuItemsMenuActionsActionItem1')).toBeEnabled();
|
||||
expect(wrapper.queryByTestId('RightSideMenuItemsMenuActionsActionItem2')).toBeDisabled();
|
||||
|
@ -103,7 +103,7 @@ describe('ExceptionListHeader', () => {
|
|||
backOptions={{ pageId: '', path: '', onNavigate }}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
fireEvent.click(wrapper.getByTestId('RightSideMenuItemsContainer'));
|
||||
expect(wrapper.getByTestId('DescriptionText')).toHaveTextContent(
|
||||
i18n.EXCEPTION_LIST_HEADER_DESCRIPTION
|
||||
|
@ -134,7 +134,7 @@ describe('ExceptionListHeader', () => {
|
|||
backOptions={{ pageId: '', path: '', onNavigate }}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('EditModal')).toBeInTheDocument();
|
||||
});
|
||||
it('should go back the page path when back button is clicked', () => {
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -30,7 +30,7 @@ describe('MenuItems', () => {
|
|||
onManageRules={onManageRules}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('LinkedRulesMenuItems')).toHaveTextContent('Linked to 1 rules');
|
||||
expect(wrapper.getByTestId('LinkRulesButton')).toBeInTheDocument();
|
||||
expect(wrapper.getByTestId('MenuActionsButtonIcon')).toBeInTheDocument();
|
||||
|
@ -47,7 +47,7 @@ describe('MenuItems', () => {
|
|||
onManageRules={onManageRules}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.queryByTestId('LinkedRulesMenuItems')).not.toBeInTheDocument();
|
||||
expect(wrapper.getByTestId('noLinkedRules')).toBeInTheDocument();
|
||||
});
|
||||
|
@ -64,7 +64,7 @@ describe('MenuItems', () => {
|
|||
/>
|
||||
);
|
||||
fireEvent.click(wrapper.getByTestId('MenuActionsButtonIcon'));
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('MenuActionsActionItem1')).toBeEnabled();
|
||||
expect(wrapper.getByTestId('MenuActionsActionItem2')).toBeEnabled();
|
||||
expect(wrapper.getByTestId('MenuActionsActionItem3')).toBeEnabled();
|
||||
|
@ -83,7 +83,7 @@ describe('MenuItems', () => {
|
|||
/>
|
||||
);
|
||||
fireEvent.click(wrapper.getByTestId('MenuActionsButtonIcon'));
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('MenuActionsActionItem1')).toBeEnabled();
|
||||
expect(wrapper.getByTestId('MenuActionsActionItem2')).toBeDisabled();
|
||||
expect(wrapper.getByTestId('MenuActionsActionItem3')).toBeDisabled();
|
||||
|
@ -101,7 +101,7 @@ describe('MenuItems', () => {
|
|||
onManageRules={onManageRules}
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.queryByTestId('LinkRulesButton')).not.toBeInTheDocument();
|
||||
});
|
||||
it('should call onManageRules', () => {
|
||||
|
|
|
@ -1,219 +1,57 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`TextWithEdit should not render the edit icon when isReadonly is true 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-l-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-10"
|
||||
>
|
||||
<span
|
||||
data-test-subj="TextWithEditTestText"
|
||||
>
|
||||
Test
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-l-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-l-flexStart-stretch-row"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-10"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-10"
|
||||
<span
|
||||
data-test-subj="TextWithEditTestText"
|
||||
>
|
||||
<span
|
||||
data-test-subj="TextWithEditTestText"
|
||||
>
|
||||
Test
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
/>
|
||||
Test
|
||||
</span>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`TextWithEdit should render the edit icon when isReadonly is false 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-l-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-10"
|
||||
>
|
||||
<span
|
||||
data-test-subj="TextWithEditTestText"
|
||||
>
|
||||
Test
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<button
|
||||
aria-label="Edit Text List Header"
|
||||
class="euiButtonIcon emotion-euiButtonIcon-xs-empty-primary"
|
||||
data-test-subj="TextWithEditTestEditIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="pencil"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-l-flexStart-stretch-row"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-l-flexStart-stretch-row"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-10"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-10"
|
||||
<span
|
||||
data-test-subj="TextWithEditTestText"
|
||||
>
|
||||
Test
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<button
|
||||
aria-label="Edit Text List Header"
|
||||
class="euiButtonIcon emotion-euiButtonIcon-xs-empty-primary"
|
||||
data-test-subj="TextWithEditTestEditIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
data-test-subj="TextWithEditTestText"
|
||||
>
|
||||
Test
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<button
|
||||
aria-label="Edit Text List Header"
|
||||
class="euiButtonIcon emotion-euiButtonIcon-xs-empty-primary"
|
||||
data-test-subj="TextWithEditTestEditIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="pencil"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="pencil"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -16,7 +16,7 @@ describe('TextWithEdit', () => {
|
|||
const wrapper = render(
|
||||
<TextWithEdit isReadonly={true} dataTestSubj="TextWithEditTest" text="Test" />
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('TextWithEditTestText')).toHaveTextContent('Test');
|
||||
expect(wrapper.queryByTestId('TextWithEditTestEditIcon')).not.toBeInTheDocument();
|
||||
});
|
||||
|
@ -24,7 +24,7 @@ describe('TextWithEdit', () => {
|
|||
const wrapper = render(
|
||||
<TextWithEdit isReadonly={false} dataTestSubj="TextWithEditTest" text="Test" />
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.getByTestId('TextWithEditTestText')).toHaveTextContent('Test');
|
||||
expect(wrapper.getByTestId('TextWithEditTestEditIcon')).toBeInTheDocument();
|
||||
});
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -44,7 +44,7 @@ describe('Tree view Breadcrumb component', () => {
|
|||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.node!)).toBeFalsy();
|
||||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.pod!)).toBeNull();
|
||||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.containerImage!)).toBeVisible();
|
||||
expect(renderResult).toMatchSnapshot();
|
||||
expect(renderResult.container).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('should render breadcrumb icons', async () => {
|
||||
|
@ -60,7 +60,7 @@ describe('Tree view Breadcrumb component', () => {
|
|||
expect(
|
||||
renderResult.queryByTestId('kubernetesSecurityBreadcrumbIcon-containerImage')
|
||||
).toBeVisible();
|
||||
expect(renderResult).toMatchSnapshot();
|
||||
expect(renderResult.container).toMatchSnapshot();
|
||||
});
|
||||
it('returns null when no selected collection', async () => {
|
||||
renderResult = mockedContext.render(<Breadcrumb treeNavSelection={{}} onSelect={onSelect} />);
|
||||
|
@ -84,7 +84,7 @@ describe('Tree view Breadcrumb component', () => {
|
|||
).toBeVisible();
|
||||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.clusterId!)).toBeNull();
|
||||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.containerImage!)).toBeVisible();
|
||||
expect(renderResult).toMatchSnapshot();
|
||||
expect(renderResult.container).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('should return null when no cluster in selection', async () => {
|
||||
|
@ -132,7 +132,7 @@ describe('Tree view Breadcrumb component', () => {
|
|||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.node!)).toBeNull();
|
||||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.pod!)).toBeNull();
|
||||
expect(renderResult.queryByText(MOCK_TREE_SELECTION.containerImage!)).toBeVisible();
|
||||
expect(renderResult).toMatchSnapshot();
|
||||
expect(renderResult.container).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,734 +1,7 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`ImportDataModal renders correctly against snapshot 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
<div
|
||||
class="euiOverlayMask emotion-euiOverlayMask-aboveHeader"
|
||||
data-euiportal="true"
|
||||
data-relative-to-header="above"
|
||||
>
|
||||
<div
|
||||
data-eui="EuiFocusTrap"
|
||||
>
|
||||
<div
|
||||
aria-modal="true"
|
||||
class="euiModal emotion-euiModal"
|
||||
role="dialog"
|
||||
style="max-inline-size: 750px;"
|
||||
tabindex="0"
|
||||
>
|
||||
<button
|
||||
aria-label="Closes this modal window"
|
||||
class="euiButtonIcon euiModal__closeIcon emotion-euiButtonIcon-xs-empty-text-euiModal__closeIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</button>
|
||||
<div
|
||||
class="euiModalHeader emotion-euiModalHeader"
|
||||
>
|
||||
<h1
|
||||
class="euiTitle euiModalHeader__title emotion-euiTitle-m"
|
||||
>
|
||||
title
|
||||
</h1>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalBody emotion-euiModalBody"
|
||||
>
|
||||
<div
|
||||
class="euiModalBody__overflow emotion-euiModalBody__overflow"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-s"
|
||||
>
|
||||
<h4
|
||||
id="generated-id"
|
||||
>
|
||||
description
|
||||
</h4>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiFilePicker emotion-euiFilePicker-fullWidth"
|
||||
>
|
||||
<input
|
||||
accept=".ndjson"
|
||||
aria-describedby="rule-file-picker-filePicker__prompt"
|
||||
aria-labelledby="generated-id"
|
||||
class="euiFilePicker__input emotion-euiFilePicker__input-largeInteractive"
|
||||
data-test-subj="rule-file-picker"
|
||||
id="rule-file-picker"
|
||||
type="file"
|
||||
/>
|
||||
<div
|
||||
class="euiFilePicker__prompt emotion-euiFilePicker__prompt-large"
|
||||
id="rule-file-picker-filePicker__prompt"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFilePicker__icon emotion-euiFilePicker__icon-large"
|
||||
color="primary"
|
||||
data-euiicon-type="importAction"
|
||||
/>
|
||||
<span
|
||||
class="euiFilePicker__promptText"
|
||||
>
|
||||
subtitle
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiCheckbox emotion-euiCheckbox"
|
||||
>
|
||||
<div
|
||||
class="euiCheckbox__square emotion-euiCheckbox__square-unselected"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiCheckbox__icon-check"
|
||||
data-euiicon-type="empty"
|
||||
/>
|
||||
<input
|
||||
class="euiCheckbox__input emotion-euiCheckbox__input"
|
||||
data-test-subj="importDataModalCheckboxLabel"
|
||||
id="importDataModalCheckboxLabel"
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
<label
|
||||
class="euiCheckbox__label emotion-euiCheckbox__label"
|
||||
for="importDataModalCheckboxLabel"
|
||||
>
|
||||
checkBoxLabel
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalFooter emotion-euiModalFooter"
|
||||
>
|
||||
<button
|
||||
class="euiButtonEmpty emotion-euiButtonDisplay-euiButtonEmpty-m-empty-primary"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiButtonEmpty__content emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate euiButtonEmpty__text"
|
||||
>
|
||||
Cancel
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-isDisabled-fill-disabled"
|
||||
data-test-subj="import-data-modal-button"
|
||||
disabled=""
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
submitBtnText
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ImportDataModal renders correctly against snapshot 1`] = `<div />`;
|
||||
|
||||
exports[`ImportDataModal should import file, with warnings 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
<div
|
||||
class="euiOverlayMask emotion-euiOverlayMask-aboveHeader"
|
||||
data-euiportal="true"
|
||||
data-relative-to-header="above"
|
||||
>
|
||||
<div
|
||||
data-eui="EuiFocusTrap"
|
||||
>
|
||||
<div
|
||||
aria-modal="true"
|
||||
class="euiModal emotion-euiModal"
|
||||
role="dialog"
|
||||
style="max-inline-size: 750px;"
|
||||
tabindex="0"
|
||||
>
|
||||
<button
|
||||
aria-label="Closes this modal window"
|
||||
class="euiButtonIcon euiModal__closeIcon emotion-euiButtonIcon-xs-empty-text-euiModal__closeIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</button>
|
||||
<div
|
||||
class="euiModalHeader emotion-euiModalHeader"
|
||||
>
|
||||
<h1
|
||||
class="euiTitle euiModalHeader__title emotion-euiTitle-m"
|
||||
>
|
||||
title
|
||||
</h1>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalBody emotion-euiModalBody"
|
||||
>
|
||||
<div
|
||||
class="euiModalBody__overflow emotion-euiModalBody__overflow"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-s"
|
||||
>
|
||||
<h4
|
||||
id="generated-id"
|
||||
>
|
||||
description
|
||||
</h4>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiFilePicker euiFilePicker-hasFiles emotion-euiFilePicker-fullWidth-hasFiles"
|
||||
>
|
||||
<input
|
||||
accept=".ndjson"
|
||||
aria-describedby="rule-file-picker-filePicker__prompt"
|
||||
aria-labelledby="generated-id"
|
||||
class="euiFilePicker__input emotion-euiFilePicker__input-largeInteractive"
|
||||
data-test-subj="rule-file-picker"
|
||||
id="rule-file-picker"
|
||||
type="file"
|
||||
/>
|
||||
<div
|
||||
class="euiFilePicker__prompt emotion-euiFilePicker__prompt-large"
|
||||
id="rule-file-picker-filePicker__prompt"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFilePicker__icon emotion-euiFilePicker__icon-large"
|
||||
color="primary"
|
||||
data-euiicon-type="importAction"
|
||||
/>
|
||||
<span
|
||||
class="euiFilePicker__promptText"
|
||||
>
|
||||
subtitle
|
||||
</span>
|
||||
<button
|
||||
aria-label="Remove selected files"
|
||||
class="euiButtonEmpty euiFilePicker__clearButton emotion-euiButtonDisplay-euiButtonEmpty-xs-empty-primary-euiFilePicker__clearButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiButtonEmpty__content emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate euiButtonEmpty__text"
|
||||
>
|
||||
Remove
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
1 connector imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
1 connector has sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
buttonLabel
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiCheckbox emotion-euiCheckbox"
|
||||
>
|
||||
<div
|
||||
class="euiCheckbox__square emotion-euiCheckbox__square-unselected"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiCheckbox__icon-check"
|
||||
data-euiicon-type="empty"
|
||||
/>
|
||||
<input
|
||||
class="euiCheckbox__input emotion-euiCheckbox__input"
|
||||
data-test-subj="importDataModalCheckboxLabel"
|
||||
id="importDataModalCheckboxLabel"
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
<label
|
||||
class="euiCheckbox__label emotion-euiCheckbox__label"
|
||||
for="importDataModalCheckboxLabel"
|
||||
>
|
||||
checkBoxLabel
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalFooter emotion-euiModalFooter"
|
||||
>
|
||||
<button
|
||||
class="euiButtonEmpty emotion-euiButtonDisplay-euiButtonEmpty-m-empty-primary"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiButtonEmpty__content emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate euiButtonEmpty__text"
|
||||
>
|
||||
Cancel
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-isDisabled-fill-disabled"
|
||||
data-test-subj="import-data-modal-button"
|
||||
disabled=""
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
submitBtnText
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ImportDataModal should import file, with warnings 1`] = `<div />`;
|
||||
|
||||
exports[`ImportDataModal should import file, with warnings but no action_connectors_success_count 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
<div
|
||||
class="euiOverlayMask emotion-euiOverlayMask-aboveHeader"
|
||||
data-euiportal="true"
|
||||
data-relative-to-header="above"
|
||||
>
|
||||
<div
|
||||
data-eui="EuiFocusTrap"
|
||||
>
|
||||
<div
|
||||
aria-modal="true"
|
||||
class="euiModal emotion-euiModal"
|
||||
role="dialog"
|
||||
style="max-inline-size: 750px;"
|
||||
tabindex="0"
|
||||
>
|
||||
<button
|
||||
aria-label="Closes this modal window"
|
||||
class="euiButtonIcon euiModal__closeIcon emotion-euiButtonIcon-xs-empty-text-euiModal__closeIcon"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="cross"
|
||||
/>
|
||||
</button>
|
||||
<div
|
||||
class="euiModalHeader emotion-euiModalHeader"
|
||||
>
|
||||
<h1
|
||||
class="euiTitle euiModalHeader__title emotion-euiTitle-m"
|
||||
>
|
||||
title
|
||||
</h1>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalBody emotion-euiModalBody"
|
||||
>
|
||||
<div
|
||||
class="euiModalBody__overflow emotion-euiModalBody__overflow"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-s"
|
||||
>
|
||||
<h4
|
||||
id="generated-id"
|
||||
>
|
||||
description
|
||||
</h4>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiFilePicker euiFilePicker-hasFiles emotion-euiFilePicker-fullWidth-hasFiles"
|
||||
>
|
||||
<input
|
||||
accept=".ndjson"
|
||||
aria-describedby="rule-file-picker-filePicker__prompt"
|
||||
aria-labelledby="generated-id"
|
||||
class="euiFilePicker__input emotion-euiFilePicker__input-largeInteractive"
|
||||
data-test-subj="rule-file-picker"
|
||||
id="rule-file-picker"
|
||||
type="file"
|
||||
/>
|
||||
<div
|
||||
class="euiFilePicker__prompt emotion-euiFilePicker__prompt-large"
|
||||
id="rule-file-picker-filePicker__prompt"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiFilePicker__icon emotion-euiFilePicker__icon-large"
|
||||
color="primary"
|
||||
data-euiicon-type="importAction"
|
||||
/>
|
||||
<span
|
||||
class="euiFilePicker__promptText"
|
||||
>
|
||||
subtitle
|
||||
</span>
|
||||
<button
|
||||
aria-label="Remove selected files"
|
||||
class="euiButtonEmpty euiFilePicker__clearButton emotion-euiButtonDisplay-euiButtonEmpty-xs-empty-primary-euiFilePicker__clearButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiButtonEmpty__content emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate euiButtonEmpty__text"
|
||||
>
|
||||
Remove
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiCheckbox emotion-euiCheckbox"
|
||||
>
|
||||
<div
|
||||
class="euiCheckbox__square emotion-euiCheckbox__square-unselected"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiCheckbox__icon-check"
|
||||
data-euiicon-type="empty"
|
||||
/>
|
||||
<input
|
||||
class="euiCheckbox__input emotion-euiCheckbox__input"
|
||||
data-test-subj="importDataModalCheckboxLabel"
|
||||
id="importDataModalCheckboxLabel"
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
<label
|
||||
class="euiCheckbox__label emotion-euiCheckbox__label"
|
||||
for="importDataModalCheckboxLabel"
|
||||
>
|
||||
checkBoxLabel
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiModalFooter emotion-euiModalFooter"
|
||||
>
|
||||
<button
|
||||
class="euiButtonEmpty emotion-euiButtonDisplay-euiButtonEmpty-m-empty-primary"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="euiButtonEmpty__content emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate euiButtonEmpty__text"
|
||||
>
|
||||
Cancel
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-isDisabled-fill-disabled"
|
||||
data-test-subj="import-data-modal-button"
|
||||
disabled=""
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
submitBtnText
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ImportDataModal should import file, with warnings but no action_connectors_success_count 1`] = `<div />`;
|
||||
|
|
|
@ -1,696 +1,212 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`ActionConnectorWarnings should not render if importedActionConnectorsCount is falsy and empty warnings array 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ActionConnectorWarnings should not render if importedActionConnectorsCount is falsy and empty warnings array 1`] = `<div />`;
|
||||
|
||||
exports[`ActionConnectorWarnings should not render if importedActionConnectorsCount is truthy and empty warnings array 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ActionConnectorWarnings should not render if importedActionConnectorsCount is truthy and empty warnings array 1`] = `<div />`;
|
||||
|
||||
exports[`ActionConnectorWarnings should render if 1 connectors were imported and use the warning message with the correct imported number 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
<div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
1 connector imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
1 connector imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
1 connector has sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Go to connectors
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
1 connector has sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
1 connector imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
1 connector has sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Go to connectors
|
||||
</span>
|
||||
Go to connectors
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`ActionConnectorWarnings should render if 2 connectors were imported and use the button label when is set 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
<div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
2 connectors imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
2 connectors imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
2 connectors have sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Connectors
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
2 connectors have sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
2 connectors imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
2 connectors have sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Connectors
|
||||
</span>
|
||||
Connectors
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`ActionConnectorWarnings should render if 2 connectors were imported and use the warning message with the correct imported number 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
<div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
2 connectors imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
2 connectors imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
>
|
||||
2 connectors have sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Go to connectors
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
2 connectors have sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiPanel euiPanel--warning euiPanel--paddingMedium euiCallOut euiCallOut--warning emotion-euiPanel-none-m-warning-euiCallOut"
|
||||
data-test-subj="actionConnectorsWarningsCallOut"
|
||||
>
|
||||
<h2
|
||||
class="euiTitle euiCallOutHeader__title emotion-euiTitle-xs-euiCallOutHeader-warning"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="emotion-euiCallOut__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="warning"
|
||||
/>
|
||||
<span
|
||||
data-test-subj="actionConnectorsWarningsCallOutTitle"
|
||||
>
|
||||
2 connectors imported
|
||||
</span>
|
||||
</h2>
|
||||
<div
|
||||
class="euiSpacer euiSpacer--s emotion-euiSpacer-s"
|
||||
/>
|
||||
<div
|
||||
class="euiText emotion-euiText-s-euiTextColor-default"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-stretch-column"
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
data-test-subj="actionConnectorsWarningsCallOutMessage"
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-euiText-xs"
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
>
|
||||
2 connectors have sensitive information that requires updates.
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-grow-1"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-none-flexStart-flexEnd-columnReverse"
|
||||
>
|
||||
<button
|
||||
class="euiButton emotion-euiButtonDisplay-m-defaultMinWidth-base-warning"
|
||||
data-test-subj="actionConnectorsWarningsCallOutButton"
|
||||
type="button"
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
>
|
||||
<span
|
||||
class="emotion-euiButtonDisplayContent"
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
<span
|
||||
class="eui-textTruncate"
|
||||
>
|
||||
Go to connectors
|
||||
</span>
|
||||
Go to connectors
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -18,14 +18,14 @@ describe('ActionConnectorWarnings', () => {
|
|||
const wrapper = render(
|
||||
<ActionConnectorWarnings actionConnectorsWarnings={[]} importedActionConnectorsCount={0} />
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.queryByTestId('actionConnectorsWarningsCallOut')).not.toBeInTheDocument();
|
||||
});
|
||||
test('should not render if importedActionConnectorsCount is truthy and empty warnings array', () => {
|
||||
const wrapper = render(
|
||||
<ActionConnectorWarnings actionConnectorsWarnings={[]} importedActionConnectorsCount={2} />
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(wrapper.queryByTestId('actionConnectorsWarningsCallOut')).not.toBeInTheDocument();
|
||||
});
|
||||
test('should render if 1 connectors were imported and use the warning message with the correct imported number', () => {
|
||||
|
@ -43,7 +43,7 @@ describe('ActionConnectorWarnings', () => {
|
|||
/>
|
||||
);
|
||||
const { getByTestId } = wrapper;
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(getByTestId('actionConnectorsWarningsCallOutTitle').textContent).toBe(
|
||||
'1 connector imported'
|
||||
);
|
||||
|
@ -66,7 +66,7 @@ describe('ActionConnectorWarnings', () => {
|
|||
/>
|
||||
);
|
||||
const { getByTestId } = wrapper;
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(getByTestId('actionConnectorsWarningsCallOutTitle').textContent).toBe(
|
||||
'2 connectors imported'
|
||||
);
|
||||
|
@ -92,7 +92,7 @@ describe('ActionConnectorWarnings', () => {
|
|||
/>
|
||||
);
|
||||
const { getByTestId } = wrapper;
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(getByTestId('actionConnectorsWarningsCallOutTitle').textContent).toBe(
|
||||
'2 connectors imported'
|
||||
);
|
||||
|
|
|
@ -51,7 +51,7 @@ describe('ImportDataModal', () => {
|
|||
title="title"
|
||||
/>
|
||||
);
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
});
|
||||
test('should import file, cleanup the states and close Modal', async () => {
|
||||
const { queryByTestId } = render(
|
||||
|
@ -225,7 +225,7 @@ describe('ImportDataModal', () => {
|
|||
await waitFor(() => {
|
||||
fireEvent.click(queryByTestId('import-data-modal-button') as HTMLButtonElement);
|
||||
});
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(queryByTestId('actionConnectorsWarningsCallOut')).not.toBeInTheDocument();
|
||||
expect(importWithWarning).toHaveBeenCalled();
|
||||
expect(closeModal).not.toHaveBeenCalled();
|
||||
|
@ -269,7 +269,7 @@ describe('ImportDataModal', () => {
|
|||
await waitFor(() => {
|
||||
fireEvent.click(queryByTestId('import-data-modal-button') as HTMLButtonElement);
|
||||
});
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
expect(wrapper.container).toMatchSnapshot();
|
||||
expect(queryByTestId('actionConnectorsWarningsCallOut')).toBeInTheDocument();
|
||||
expect(importWithWarning).toHaveBeenCalled();
|
||||
expect(importComplete).toHaveBeenCalled();
|
||||
|
|
|
@ -1,217 +1,28 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`ValueWithSpaceWarning should not render if showSpaceWarning is falsy 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ValueWithSpaceWarning should not render if showSpaceWarning is falsy 1`] = `<div />`;
|
||||
|
||||
exports[`ValueWithSpaceWarning should not render if value is falsy 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div />
|
||||
</body>,
|
||||
"container": <div />,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
`;
|
||||
exports[`ValueWithSpaceWarning should not render if value is falsy 1`] = `<div />`;
|
||||
|
||||
exports[`ValueWithSpaceWarning should render if showSpaceWarning is truthy 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
.c0 {
|
||||
.c0 {
|
||||
display: inline;
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
<div>
|
||||
<div
|
||||
class="c0"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
color="warning"
|
||||
data-euiicon-type="iInCircle"
|
||||
data-test-subj="value_with_space_warning_tooltip"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="sc-AxjAm dmOCRD"
|
||||
<div
|
||||
class="c0"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
color="warning"
|
||||
data-euiicon-type="iInCircle"
|
||||
data-test-subj="value_with_space_warning_tooltip"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
color="warning"
|
||||
data-euiicon-type="iInCircle"
|
||||
data-test-subj="value_with_space_warning_tooltip"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -24,7 +24,7 @@ describe('ValueWithSpaceWarning', () => {
|
|||
});
|
||||
it('should not render if value is falsy', () => {
|
||||
const container = render(<ValueWithSpaceWarning value="" />);
|
||||
expect(container).toMatchSnapshot();
|
||||
expect(container.container).toMatchSnapshot();
|
||||
});
|
||||
it('should not render if showSpaceWarning is falsy', () => {
|
||||
// @ts-ignore
|
||||
|
@ -33,7 +33,7 @@ describe('ValueWithSpaceWarning', () => {
|
|||
.mockReturnValue({ showSpaceWarningIcon: false, warningText: '' });
|
||||
|
||||
const container = render(<ValueWithSpaceWarning value="Test" />);
|
||||
expect(container).toMatchSnapshot();
|
||||
expect(container.container).toMatchSnapshot();
|
||||
});
|
||||
it('should render if showSpaceWarning is truthy', () => {
|
||||
const container = render(
|
||||
|
@ -41,7 +41,7 @@ describe('ValueWithSpaceWarning', () => {
|
|||
<ValueWithSpaceWarning value="Test" />
|
||||
</ThemeProvider>
|
||||
);
|
||||
expect(container).toMatchSnapshot();
|
||||
expect(container.container).toMatchSnapshot();
|
||||
});
|
||||
it('should show the tooltip when the icon is clicked', async () => {
|
||||
const container = render(
|
||||
|
|
|
@ -1,88 +1,18 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`DetailPanelCopy component When DetailPanelCopy is mounted renders DetailPanelCopy correctly 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="sessionView:detail-panel-list-item"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span>
|
||||
copy component test
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="sessionView:detail-panel-list-item"
|
||||
<div>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="sessionView:detail-panel-list-item"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span>
|
||||
copy component test
|
||||
</span>
|
||||
<span>
|
||||
copy component test
|
||||
</span>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -30,7 +30,7 @@ describe('DetailPanelCopy component', () => {
|
|||
);
|
||||
|
||||
expect(renderResult.queryByText(TEST_TEXT_COPY)).toBeVisible();
|
||||
expect(renderResult).toMatchSnapshot();
|
||||
expect(renderResult.container).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -1,250 +1,99 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`ProcessTreeAlerts component When ProcessTreeAlert is mounted should render alert row correctly 1`] = `
|
||||
Object {
|
||||
"asFragment": [Function],
|
||||
"baseElement": <body>
|
||||
<div>
|
||||
<div
|
||||
css="[object Object]"
|
||||
data-id="6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="sessionView:sessionViewAlertDetail-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<button
|
||||
aria-label="expand"
|
||||
class="euiButtonIcon emotion-euiButtonIcon-xs-empty-primary"
|
||||
data-test-subj="sessionView:sessionViewAlertDetailExpand-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="expand"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
color="danger"
|
||||
data-euiicon-type="gear"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
css="[object Object]"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="sessionView:sessionViewAlertDetailRuleName-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38-text"
|
||||
>
|
||||
cmd test alert
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="open"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
open
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="exec"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
exec
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>,
|
||||
"container": <div>
|
||||
<div>
|
||||
<div
|
||||
css="[object Object]"
|
||||
data-id="6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
>
|
||||
<div
|
||||
css="[object Object]"
|
||||
data-id="6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="sessionView:sessionViewAlertDetail-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
>
|
||||
<div
|
||||
class="euiFlexGroup emotion-euiFlexGroup-responsive-wrap-s-flexStart-center-row"
|
||||
data-test-subj="sessionView:sessionViewAlertDetail-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<button
|
||||
aria-label="expand"
|
||||
class="euiButtonIcon emotion-euiButtonIcon-xs-empty-primary"
|
||||
data-test-subj="sessionView:sessionViewAlertDetailExpand-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="expand"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
color="danger"
|
||||
data-euiicon-type="gear"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<button
|
||||
aria-label="expand"
|
||||
class="euiButtonIcon emotion-euiButtonIcon-xs-empty-primary"
|
||||
data-test-subj="sessionView:sessionViewAlertDetailExpand-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38"
|
||||
type="button"
|
||||
>
|
||||
<span
|
||||
aria-hidden="true"
|
||||
class="euiButtonIcon__icon"
|
||||
color="inherit"
|
||||
data-euiicon-type="expand"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiToolTipAnchor emotion-euiToolTipAnchor-inlineBlock"
|
||||
>
|
||||
<span
|
||||
color="danger"
|
||||
data-euiicon-type="gear"
|
||||
/>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
css="[object Object]"
|
||||
>
|
||||
<div
|
||||
css="[object Object]"
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="sessionView:sessionViewAlertDetailRuleName-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38-text"
|
||||
>
|
||||
<div
|
||||
class="euiText emotion-EuiText"
|
||||
data-test-subj="sessionView:sessionViewAlertDetailRuleName-6bb22512e0e588d1a2449b61f164b216e366fba2de39e65d002ae734d71a6c38-text"
|
||||
>
|
||||
cmd test alert
|
||||
</div>
|
||||
|
||||
cmd test alert
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="open"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
open
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="exec"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
exec
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
/>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="open"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
open
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
>
|
||||
<span
|
||||
class="euiBadge emotion-EuiInnerText"
|
||||
title="exec"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__content emotion-euiBadge__content"
|
||||
>
|
||||
<span
|
||||
class="euiBadge__text emotion-euiBadge__text"
|
||||
>
|
||||
exec
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
<div
|
||||
class="euiFlexItem emotion-euiFlexItem-growZero"
|
||||
/>
|
||||
</div>
|
||||
</div>,
|
||||
"debug": [Function],
|
||||
"findAllByAltText": [Function],
|
||||
"findAllByDisplayValue": [Function],
|
||||
"findAllByLabelText": [Function],
|
||||
"findAllByPlaceholderText": [Function],
|
||||
"findAllByRole": [Function],
|
||||
"findAllByTestId": [Function],
|
||||
"findAllByText": [Function],
|
||||
"findAllByTitle": [Function],
|
||||
"findByAltText": [Function],
|
||||
"findByDisplayValue": [Function],
|
||||
"findByLabelText": [Function],
|
||||
"findByPlaceholderText": [Function],
|
||||
"findByRole": [Function],
|
||||
"findByTestId": [Function],
|
||||
"findByText": [Function],
|
||||
"findByTitle": [Function],
|
||||
"getAllByAltText": [Function],
|
||||
"getAllByDisplayValue": [Function],
|
||||
"getAllByLabelText": [Function],
|
||||
"getAllByPlaceholderText": [Function],
|
||||
"getAllByRole": [Function],
|
||||
"getAllByTestId": [Function],
|
||||
"getAllByText": [Function],
|
||||
"getAllByTitle": [Function],
|
||||
"getByAltText": [Function],
|
||||
"getByDisplayValue": [Function],
|
||||
"getByLabelText": [Function],
|
||||
"getByPlaceholderText": [Function],
|
||||
"getByRole": [Function],
|
||||
"getByTestId": [Function],
|
||||
"getByText": [Function],
|
||||
"getByTitle": [Function],
|
||||
"queryAllByAltText": [Function],
|
||||
"queryAllByDisplayValue": [Function],
|
||||
"queryAllByLabelText": [Function],
|
||||
"queryAllByPlaceholderText": [Function],
|
||||
"queryAllByRole": [Function],
|
||||
"queryAllByTestId": [Function],
|
||||
"queryAllByText": [Function],
|
||||
"queryAllByTitle": [Function],
|
||||
"queryByAltText": [Function],
|
||||
"queryByDisplayValue": [Function],
|
||||
"queryByLabelText": [Function],
|
||||
"queryByPlaceholderText": [Function],
|
||||
"queryByRole": [Function],
|
||||
"queryByTestId": [Function],
|
||||
"queryByText": [Function],
|
||||
"queryByTitle": [Function],
|
||||
"rerender": [Function],
|
||||
"unmount": [Function],
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
|
|
@ -45,7 +45,7 @@ describe('ProcessTreeAlerts component', () => {
|
|||
expect(renderResult.queryByText(ALERT_RULE_NAME!)).toBeTruthy();
|
||||
expect(renderResult.queryByText(ALERT_STATUS!)).toBeTruthy();
|
||||
|
||||
expect(renderResult).toMatchSnapshot();
|
||||
expect(renderResult.container).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('should execute onClick callback', async () => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue