-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update spy table headers when columns update (#13130)
* update paginated table headers with columns update * remove unneeded sleep * update getDataTableHeaders to preffered format * use data-test-subj attribute for functional tests instead of CSS selectors
- Loading branch information
Showing
4 changed files
with
59 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import expect from 'expect.js'; | ||
|
||
export default function ({ getService, getPageObjects }) { | ||
const log = getService('log'); | ||
const PageObjects = getPageObjects(['common', 'visualize', 'header']); | ||
|
||
describe('visualize app', function describeIndexTests() { | ||
before(async function () { | ||
const fromTime = '2015-09-19 06:31:44.000'; | ||
const toTime = '2015-09-23 18:31:44.000'; | ||
|
||
await PageObjects.common.navigateToUrl('visualize', 'new'); | ||
await PageObjects.visualize.clickVerticalBarChart(); | ||
await PageObjects.visualize.clickNewSearch(); | ||
|
||
log.debug('Set absolute time range from \"' + fromTime + '\" to \"' + toTime + '\"'); | ||
await PageObjects.header.setAbsoluteRange(fromTime, toTime); | ||
await PageObjects.visualize.clickGo(); | ||
await PageObjects.header.waitUntilLoadingHasFinished(); | ||
}); | ||
|
||
describe('spy panel tabel', function indexPatternCreation() { | ||
|
||
it('should update table header when columns change', async function () { | ||
|
||
await PageObjects.visualize.openSpyPanel(); | ||
let headers = await PageObjects.visualize.getDataTableHeaders(); | ||
expect(headers.trim()).to.equal('Count'); | ||
|
||
log.debug('Add Average Metric on machine.ram field'); | ||
await PageObjects.visualize.clickAddMetric(); | ||
await PageObjects.visualize.clickBucket('Y-Axis'); | ||
await PageObjects.visualize.selectAggregation('Average'); | ||
await PageObjects.visualize.selectField('machine.ram', 'metrics'); | ||
await PageObjects.visualize.clickGo(); | ||
await PageObjects.visualize.openSpyPanel(); | ||
|
||
headers = await PageObjects.visualize.getDataTableHeaders(); | ||
expect(headers.trim()).to.equal('Count Average machine.ram'); | ||
}); | ||
}); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters