Skip to content

Commit

Permalink
fix(ui5-shellbar): fix volatile test (#8411)
Browse files Browse the repository at this point in the history
* fix(ui5-shellbar): fix volatile test

Fixes: #8409
  • Loading branch information
plamenivanov91 authored Mar 8, 2024
1 parent e2a6552 commit 7e6bf4b
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions packages/fiori/test/specs/ShellBar.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -546,30 +546,18 @@ describe("Component Behavior", () => {
});

it("Shows translated label for predefined buttons, as button text when in Overflow Popover", async () => {
await browser.url(`test/pages/ShellBar.html?sap-ui-language=de_DE`);
const shellBar = await browser.$("#shellbar");
const overflowButton = await shellBar.shadow$(".ui5-shellbar-overflow-button");
let psButtonText;

await browser.executeAsync(function(done) {
window['sap-ui-webcomponents-bundle'].configuration.setLanguage("de_DE");
done();
});
await browser.setWindowSize(500, 1080);

overflowButton.click();
const popover = await getOverflowPopover("shellbar");
const items = await popover.$$("ui5-li");
await overflowButton.click();

psButtonText = await [...items][5].getText();

assert.strictEqual(psButtonText, await shellBar.getProperty("_productsText"), "Product switch button text is translated in overflow popover");

await browser.setWindowSize(500, 1080);
await browser.executeAsync(function(done) {
window['sap-ui-webcomponents-bundle'].configuration.setLanguage("en_EN");
done();
});

});
});
});
Expand Down

0 comments on commit 7e6bf4b

Please sign in to comment.