ui5-uiveri5
ui5-uiveri5 copied to clipboard
Limit in the View Settings dialog
I have an issue regarding the View Settings dialog in UI5 apps:
I have an assertion to check number of records in View Settings dialog:
expect(settingsWindow.getAllPossibleFields().count()).toEqual(Constants.adaptTable.additionalColumns.length); //shoul be some number, in this case 66
getAllPossibleFields() {
let xpath = '//td[@class="sapMListTblCell"]//bdi';
return this.getAllByXPath(xpath);
In all of our apps no matter how many records in View Settings dialog there is, It seems the limit stored in the count() is always 25
I can't comment what this XPath returns, can you please run it in browser control and confirm what number it would really give?
thank you Maxim for you reply I evaluated using following expression in the console
$x('//td[@class="sapMListTblCell"]//bdi').length
and the result is 70
Maybe this getAllByXPath adds another level of filtering, for example showing only visible items ?
I dont think that the issue is in the getAllByXPath
I use another function: it checks whether the column is present in the dialog, it loops the list of columns that should be there:
hasColumnsUnderSettings: function(columns) { columns.forEach(column => { expect(tableBuilderInstance.getAvailableColumnName(column).isPresent()).toBeTruthy('Column ' + column + ' is visible'); });
You can see that the resulting number of hits returned by XPATH is 1, and the column "WIP" is not visible in the screen
I normally use isDisplayed in the function, but when I use isPresent, as you can see in the code snippet, It is strange that the limit is reached eventhough isPresent checks just if the element is present in DOM
Is this issue still relevant?