Skip to content

Commit

Permalink
Fix upgrade tests for 7.14 (elastic#104993) (elastic#105273)
Browse files Browse the repository at this point in the history
* Fix upgrade tests for 7.14

* Fix lint issues

* Comment out unused const

* Update uiSettings for non-default space

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: liza-mae <liza-mae@users.noreply.github.com>
  • Loading branch information
kibanamachine and liza-mae committed Jul 13, 2021
1 parent b126986 commit dbd652f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
15 changes: 12 additions & 3 deletions x-pack/test/upgrade/apps/dashboard/dashboard_smoke_tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
const renderable = getService('renderable');
const dashboardExpect = getService('dashboardExpect');
const PageObjects = getPageObjects(['common', 'header', 'home', 'dashboard', 'timePicker']);
const kibanaServer = getService('kibanaServer');
const browser = getService('browser');

describe('dashboard smoke tests', function describeIndexTests() {
const spaces = [
Expand All @@ -36,6 +38,14 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
basePath,
});
await PageObjects.header.waitUntilLoadingHasFinished();
await kibanaServer.uiSettings.update(
{
'visualization:visualize:legacyChartsLibrary': true,
'visualization:visualize:legacyPieChartsLibrary': true,
},
{ space }
);
await browser.refresh();
});
dashboardTests.forEach(({ name, numPanels }) => {
it('should launch sample ' + name + ' data set dashboard', async () => {
Expand All @@ -56,9 +66,8 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
await renderable.waitForRender();
log.debug('Checking pie charts rendered');
await pieChart.expectPieSliceCount(4);
// https://github.com/elastic/kibana/issues/92887
// log.debug('Checking area, bar and heatmap charts rendered');
// await dashboardExpect.seriesElementCount(15);
log.debug('Checking area, bar and heatmap charts rendered');
await dashboardExpect.seriesElementCount(15);
log.debug('Checking saved searches rendered');
await dashboardExpect.savedSearchRowCount(49);
log.debug('Checking input controls rendered');
Expand Down
2 changes: 2 additions & 0 deletions x-pack/test/upgrade/apps/reporting/reporting_smoke_tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
if (type === 'pdf_optimize') {
await testSubjects.click('usePrintLayout');
}
const advOpt = await find.byXPath(`//button[descendant::*[text()='Advanced options']]`);
await advOpt.click();
const postUrl = await find.byXPath(`//button[descendant::*[text()='Copy POST URL']]`);
await postUrl.click();
const url = await browser.getClipboardValue();
Expand Down

0 comments on commit dbd652f

Please sign in to comment.