Test for ensuring that options *hide all panel titles" work on dashboards. (#17440) (#17459)

Test for making sure option hide all panel titles work
This commit is contained in:
Bhavya RM 2018-03-29 19:13:49 -04:00 committed by GitHub
parent 557f5e3ec9
commit c4e71d733a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 26 additions and 0 deletions

View file

@ -103,6 +103,23 @@ export default function ({ getService, getPageObjects }) {
});
});
it('should be able to hide all panel titles', async function () {
await PageObjects.dashboard.checkHideTitle();
await retry.tryForTime(10000, async function () {
const titles = await PageObjects.dashboard.getPanelTitles();
expect(titles[0]).to.eql('');
});
});
it('should be able to unhide all panel titles', async function () {
await PageObjects.dashboard.checkHideTitle();
await retry.tryForTime(10000, async function () {
const titles = await PageObjects.dashboard.getPanelTitles();
expect(titles[0]).to.eql('TSVB');
});
});
describe('expanding a panel', () => {
it('hides other panels', async () => {
// Don't expand TSVB since it doesn't have the spy panel.
@ -236,6 +253,8 @@ export default function ({ getService, getPageObjects }) {
expect(isChromeVisible).to.be(true);
});
});
});
describe('add new visualization link', () => {

View file

@ -605,6 +605,13 @@ export function DashboardPageProvider({ getService, getPageObjects }) {
};
}));
}
async checkHideTitle() {
log.debug('ensure that you can click on hide title checkbox');
await this.openOptions();
return await testSubjects.click('dashboardPanelTitlesCheckbox');
}
}
return new DashboardPage();