Skip to content

Commit

Permalink
Add data-test-subj tags.
Browse files Browse the repository at this point in the history
Signed-off-by: Argus Li <[email protected]>
  • Loading branch information
ArgusLi committed Dec 10, 2024
1 parent 3c3e64b commit 47ecb97
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ export const DatasetExplorer = ({
<EuiModalBody>
<div
className="datasetExplorer"
data-test-subj="datasetExplorerWindow"
style={{
gridTemplateColumns: `repeat(${
columnCount - 1
Expand Down
7 changes: 6 additions & 1 deletion src/plugins/data/public/ui/filter_bar/filter_bar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,12 @@ function FilterBarUI(props: Props) {

function renderItems() {
return props.filters.map((filter, i) => (
<EuiFlexItem key={i} grow={false} className="globalFilterBar__flexItem">
<EuiFlexItem
key={i}
grow={false}
className="globalFilterBar__flexItem"
data-test-subj="globalFilterBar"
>
<FilterItem
id={`${i}`}
intl={props.intl}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ test('alias with warning status', () => {
:
<span
class="globalFilterLabel__value"
data-test-subj="globalFilterLabelValue"
>
Warning
</span>
Expand Down Expand Up @@ -125,6 +126,7 @@ test('alias with error status', () => {
:
<span
class="globalFilterLabel__value"
data-test-subj="globalFilterLabelValue"
>
Error
</span>
Expand All @@ -141,6 +143,7 @@ test('warning', () => {
:
<span
class="globalFilterLabel__value"
data-test-subj="globalFilterLabelValue"
>
Warning
</span>
Expand All @@ -157,6 +160,7 @@ test('error', () => {
:
<span
class="globalFilterLabel__value"
data-test-subj="globalFilterLabelValue"
>
Error
</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,11 @@ export default function FilterLabel({ filter, valueLabel, filterLabelStatus }: F
);

const getValue = (text?: string) => {
return <span className="globalFilterLabel__value">{text}</span>;
return (
<span className="globalFilterLabel__value" data-test-subj="globalFilterLabelValue">
{text}
</span>
);
};

if (filter.meta.alias !== null) {
Expand Down

0 comments on commit 47ecb97

Please sign in to comment.