[8.13] [Discover] Unskip discover data grid row height functional test (#179453) (#179690)

# Backport

This will backport the following commits from `main` to `8.13`:
- [[Discover] Unskip discover data grid row height functional test
(#179453)](https://github.com/elastic/kibana/pull/179453)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Matthias
Wilhelm","email":"matthias.wilhelm@elastic.co"},"sourceCommit":{"committedDate":"2024-03-29T13:23:58Z","message":"[Discover]
Unskip discover data grid row height functional test
(#179453)","sha":"a464a6636aab0f32f54b12690ddc77cdf4c7a36f","branchLabelMapping":{"^v8.14.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Feature:Discover","release_note:skip","documentation","Team:DataDiscovery","backport:prev-minor","v8.14.0"],"title":"[Discover]
Unskip discover data grid row height functional
test","number":179453,"url":"https://github.com/elastic/kibana/pull/179453","mergeCommit":{"message":"[Discover]
Unskip discover data grid row height functional test
(#179453)","sha":"a464a6636aab0f32f54b12690ddc77cdf4c7a36f"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v8.14.0","branchLabelMappingKey":"^v8.14.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/179453","number":179453,"mergeCommit":{"message":"[Discover]
Unskip discover data grid row height functional test
(#179453)","sha":"a464a6636aab0f32f54b12690ddc77cdf4c7a36f"}}]}]
BACKPORT-->

Co-authored-by: Matthias Wilhelm <matthias.wilhelm@elastic.co>
This commit is contained in:
Kibana Machine 2024-03-29 10:34:50 -04:00 committed by GitHub
parent c1e53e5978
commit 053db7fc01
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -370,9 +370,16 @@ export class DataGridService extends FtrService {
const buttonGroup = await this.testSubjects.find(
'unifiedDataTableRowHeightSettings_rowHeightButtonGroup'
);
return (
await buttonGroup.findByCssSelector('.euiButtonGroupButton-isSelected')
).getVisibleText();
let value = '';
await this.retry.waitFor('row height value not to be empty', async () => {
// to prevent flakiness
const selectedButton = await buttonGroup.findByCssSelector(
'.euiButtonGroupButton-isSelected'
);
value = await selectedButton.getVisibleText();
return value !== '';
});
return value;
}
public async changeRowHeightValue(newValue: string) {